<?php

declare (strict_types=1);
namespace SearchWP\Dependencies\PackageVersions;

use SearchWP\Dependencies\Composer\InstalledVersions;
use OutOfBoundsException;
\class_exists(InstalledVersions::class);
/**
 * This class is generated by composer/package-versions-deprecated, specifically by
 * @see \PackageVersions\Installer
 *
 * This file is overwritten at every run of `composer install` or `composer update`.
 *
 * @deprecated in favor of the Composer\InstalledVersions class provided by Composer 2. Require composer-runtime-api:^2 to ensure it is present.
 */
final class Versions
{
    /**
     * @deprecated please use {@see self::rootPackageName()} instead.
     *             This constant will be removed in version 2.0.0.
     */
    const ROOT_PACKAGE_NAME = 'searchwp/searchwp';
    /**
     * Array of all available composer packages.
     * Dont read this array from your calling code, but use the \PackageVersions\Versions::getVersion() method instead.
     *
     * @var array<string, string>
     * @internal
     */
    const VERSIONS = array('dekor/php-array-table' => '1.0@949fc2780656a24363e6f5706525d13c81e1e395', 'doctrine/sql-formatter' => '1.1.3@25a06c7bf4c6b8218f47928654252863ffc890a5', 'henck/rtf-to-html' => '1.2@ff984a1d44fa359c85c0cffa0d66e991bf4dc967', 'monolog/monolog' => '2.8.0@720488632c590286b88b80e62aa3d3d551ad4a50', 'psr/log' => '1.1.4@d49695b909c3b7628b6289db5479a1c204601f11', 'smalot/pdfparser' => 'v2.3.0@70433d171a86dc881fc8c68fd6af4d60acb8313e', 'symfony/polyfill-iconv' => 'v1.27.0@927013f3aac555983a5059aada98e1907d842695', 'symfony/polyfill-intl-grapheme' => 'v1.27.0@511a08c03c1960e08a883f4cffcacd219b758354', 'symfony/polyfill-intl-normalizer' => 'v1.27.0@19bd1e4fcd5b91116f14d8533c57831ed00571b6', 'symfony/polyfill-mbstring' => 'v1.27.0@8ad114f6b39e2c98a8b0e3bd907732c207c2b534', 'symfony/polyfill-php72' => 'v1.27.0@869329b1e9894268a8a61dabb69153029b7a8c97', 'voku/portable-ascii' => '2.0.1@b56450eed252f6801410d810c8e1727224ae0743', 'voku/portable-utf8' => '6.0.12@db0583727bb17666bbd2ba238c85babb973fd165', 'wamania/php-stemmer' => 'v3.0.0@eab7b93465eb3d5da372806c8e1b01da5766aea5', 'antecedent/patchwork' => '2.1.21@25c1fa0cd9a6e6d0d13863d8df8f050b6733f16d', 'behat/gherkin' => 'v4.9.0@0bc8d1e30e96183e4f36db9dc79caead300beff4', 'bordoni/phpass' => '0.3.6@12f8f5cc03ebb7efd69554f104afe9aa1aa46e1a', 'codeception/codeception' => '4.2.2@b88014f3348c93f3df99dc6d0967b0dbfa804474', 'codeception/lib-asserts' => '2.0.1@78c55044611437988b54e1daecf13f247a742bf8', 'codeception/phpunit-wrapper' => '9.0.9@7439a53ae367986e9c22b2ac00f9d7376bb2f8cf', 'codeception/stub' => '4.0.2@18a148dacd293fc7b044042f5aa63a82b08bff5d', 'composer/package-versions-deprecated' => '1.11.99.5@b4f54f74ef3453349c24a845d22392cd31e65f1d', 'dg/mysql-dump' => 'v1.5.1@e0e287b715b43293773a8b0edf8514f606e01780', 'doctrine/inflector' => '2.0.6@d9d313a36c872fd6ee06d9a6cbcf713eaa40f024', 'doctrine/instantiator' => '1.5.0@0a0fa9780f5d4e507415a065172d26a98d02047b', 'fidry/console' => '0.5.5@bc1fe03f600c63f12ec0a39c6b746c1a1fb77bf7', 'guzzlehttp/psr7' => '2.4.3@67c26b443f348a51926030c83481b85718457d3d', 'humbug/php-scoper' => '0.17.5@f67ae1e5360259911d6c4be871e4aeb4e6661541', 'illuminate/contracts' => 'v6.20.44@2aeb1ea8985f7a79abaf7186234c94b543a04165', 'illuminate/support' => 'v6.20.44@c625fd884620c41ea6c5d84ccdb6a39fe555282d', 'jetbrains/phpstorm-stubs' => 'v2022.3@6b568c153cea002dc6fad96285c3063d07cab18d', 'lucatume/wp-browser' => '3.1.6@5cefdab50d16f69447c48e5a8668d67d4892d6ef', 'mikehaertl/php-shellcommand' => '1.6.4@3488d7803df1e8f1a343d3d0ca452d527ad8d5e5', 'mikemclin/laravel-wp-password' => '2.0.3@5225c95f75aa0a5ad4040ec2074d1c8d7f10b5f4', 'mustache/mustache' => 'v2.14.2@e62b7c3849d22ec55f3ec425507bf7968193a6cb', 'myclabs/deep-copy' => '1.11.0@14daed4296fae74d9e3201d2c4925d1acb7aa614', 'nesbot/carbon' => '2.66.0@496712849902241f04902033b0441b269effe001', 'nikic/php-parser' => 'v4.15.3@570e980a201d8ed0236b0a62ddf2c9cbb2034039', 'phar-io/manifest' => '2.0.3@97803eca37d319dfa7826cc2437fc020857acb53', 'phar-io/version' => '3.2.1@4f7fd7836c6f332bb2933569e566a0d6c4cbed74', 'phpunit/php-code-coverage' => '9.2.24@2cf940ebc6355a9d430462811b5aaa308b174bed', 'phpunit/php-file-iterator' => '3.0.6@cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf', 'phpunit/php-invoker' => '3.1.1@5a10147d0aaf65b58940a0b72f71c9ac0423cc67', 'phpunit/php-text-template' => '2.0.4@5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28', 'phpunit/php-timer' => '5.0.3@5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2', 'phpunit/phpunit' => '9.5.28@954ca3113a03bf780d22f07bf055d883ee04b65e', 'psr/container' => '1.1.2@513e0666f7216c7459170d56df27dfcefe1689ea', 'psr/event-dispatcher' => '1.0.0@dbefd12671e8a14ec7f180cab83036ed26714bb0', 'psr/http-factory' => '1.0.1@12ac7fcd07e5b077433f5f2bee95b3a771bf61be', 'psr/http-message' => '1.0.1@f6561bf28d520154e4b0ec72be95418abe6d9363', 'psr/simple-cache' => '1.0.1@408d5eafb83c57f6365a3ca330ff23aa4a5fa39b', 'ralouphie/getallheaders' => '3.0.3@120b605dfeb996808c31b6477290a714d356e822', 'rmccue/requests' => 'v1.8.1@82e6936366eac3af4d836c18b9d8c31028fe4cd5', 'roave/security-advisories' => 'dev-latest@85ea494f3599c1d23c81c65d0c994e0f80895a75', 'sebastian/cli-parser' => '1.0.1@442e7c7e687e42adc03470c7b668bc4b2402c0b2', 'sebastian/code-unit' => '1.0.8@1fc9f64c0927627ef78ba436c9b17d967e68e120', 'sebastian/code-unit-reverse-lookup' => '2.0.3@ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5', 'sebastian/comparator' => '4.0.8@fa0f136dd2334583309d32b62544682ee972b51a', 'sebastian/complexity' => '2.0.2@739b35e53379900cc9ac327b2147867b8b6efd88', 'sebastian/diff' => '4.0.4@3461e3fccc7cfdfc2720be910d3bd73c69be590d', 'sebastian/environment' => '5.1.4@1b5dff7bb151a4db11d49d90e5408e4e938270f7', 'sebastian/exporter' => '4.0.5@ac230ed27f0f98f597c8a2b6eb7ac563af5e5b9d', 'sebastian/global-state' => '5.0.5@0ca8db5a5fc9c8646244e629625ac486fa286bf2', 'sebastian/lines-of-code' => '1.0.3@c1c2e997aa3146983ed888ad08b15470a2e22ecc', 'sebastian/object-enumerator' => '4.0.4@5c9eeac41b290a3712d88851518825ad78f45c71', 'sebastian/object-reflector' => '2.0.4@b4f479ebdbf63ac605d183ece17d8d7fe49c15c7', 'sebastian/recursion-context' => '4.0.4@cd9d8cf3c5804de4341c283ed787f099f5506172', 'sebastian/resource-operations' => '3.0.3@0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8', 'sebastian/type' => '3.2.0@fb3fe09c5f0bae6bc27ef3ce933a1e0ed9464b6e', 'sebastian/version' => '3.0.2@c6c1022351a901512170118436c764e473f6de8c', 'symfony/console' => 'v5.4.19@dccb8d251a9017d5994c988b034d3e18aaabf740', 'symfony/css-selector' => 'v5.4.19@f4a7d150f5b9e8f974f6f127d8167e420d11fc62', 'symfony/deprecation-contracts' => 'v2.5.2@e8b495ea28c1d97b5e0c121748d6f9b53d075c66', 'symfony/event-dispatcher' => 'v5.4.19@abf49cc084c087d94b4cb939c3f3672971784e0c', 'symfony/event-dispatcher-contracts' => 'v2.5.2@f98b54df6ad059855739db6fcbc2d36995283fe1', 'symfony/filesystem' => 'v5.4.19@648bfaca6a494f3e22378123bcee2894045dc9d8', 'symfony/finder' => 'v5.4.19@6071aebf810ad13fe8200c224f36103abb37cf1f', 'symfony/polyfill-ctype' => 'v1.27.0@5bbc823adecdae860bb64756d639ecfec17b050a', 'symfony/polyfill-php80' => 'v1.27.0@7a6ff3f1959bb01aefccb463a0f2cd3d3d2fd936', 'symfony/polyfill-php81' => 'v1.27.0@707403074c8ea6e2edaf8794b0157a0bfa52157a', 'symfony/service-contracts' => 'v2.5.2@4b426aac47d6427cc1a1d0f7e2ac724627f5966c', 'symfony/string' => 'v5.4.19@0a01071610fd861cc160dfb7e2682ceec66064cb', 'symfony/translation' => 'v5.4.19@83d487b13b7fb4c0a6ad079f4e4c9b4525e1b695', 'symfony/translation-contracts' => 'v2.5.2@136b19dd05cdf0709db6537d058bcab6dd6e2dbe', 'symfony/yaml' => 'v5.4.19@71c05db20cb9b54d381a28255f17580e2b7e36a5', 'thecodingmachine/safe' => 'v1.3.3@a8ab0876305a4cdaef31b2350fcb9811b5608dbc', 'theseer/tokenizer' => '1.2.1@34a41e998c2183e22995f158c581e7b5e755ab9e', 'vria/nodiacritic' => '0.1.2@3efeb60fb2586fe3ce8ff0f3c122d380717b8b07', 'webmozart/assert' => '1.11.0@11cb2199493b2f8a3b53e7f19068fc6aac760991', 'wp-cli/mustangostang-spyc' => '0.6.3@6aa0b4da69ce9e9a2c8402dab8d43cf32c581cc7', 'wp-cli/php-cli-tools' => 'v0.11.17@f6be76b7c4ee2ef93c9531b8a37bdb7ce42c3728', 'wp-cli/wp-cli' => 'v2.7.1@1ddc754f1c15e56fb2cdd1a4e82bd0ec6ca32a76', 'zordius/lightncandy' => 'v1.2.6@b451f73e8b5c73e62e365997ba3c993a0376b72a', 'searchwp/searchwp' => 'dev-master@f995c533017621de383c56499b46ebdc8171bde6');
    private function __construct()
    {
    }
    /**
     * @psalm-pure
     *
     * @psalm-suppress ImpureMethodCall we know that {@see InstalledVersions} interaction does not
     *                                  cause any side effects here.
     */
    public static function rootPackageName() : string
    {
        if (!self::composer2ApiUsable()) {
            return self::ROOT_PACKAGE_NAME;
        }
        return InstalledVersions::getRootPackage()['name'];
    }
    /**
     * @throws OutOfBoundsException If a version cannot be located.
     *
     * @psalm-param key-of<self::VERSIONS> $packageName
     * @psalm-pure
     *
     * @psalm-suppress ImpureMethodCall we know that {@see InstalledVersions} interaction does not
     *                                  cause any side effects here.
     */
    public static function getVersion(string $packageName) : string
    {
        if (self::composer2ApiUsable()) {
            return InstalledVersions::getPrettyVersion($packageName) . '@' . InstalledVersions::getReference($packageName);
        }
        if (isset(self::VERSIONS[$packageName])) {
            return self::VERSIONS[$packageName];
        }
        throw new OutOfBoundsException('Required package "' . $packageName . '" is not installed: check your ./vendor/composer/installed.json and/or ./composer.lock files');
    }
    private static function composer2ApiUsable() : bool
    {
        if (!\class_exists(InstalledVersions::class, \false)) {
            return \false;
        }
        if (\method_exists(InstalledVersions::class, 'getAllRawData')) {
            $rawData = InstalledVersions::getAllRawData();
            if (\count($rawData) === 1 && \count($rawData[0]) === 0) {
                return \false;
            }
        } else {
            $rawData = InstalledVersions::getRawData();
            if ($rawData === null || $rawData === []) {
                return \false;
            }
        }
        return \true;
    }
}
