PHP 8.2.31
Preview: Registry.php Size: 1.02 KB
/opt/cpanel/ea-wappspector/vendor/phpunit/phpunit/src/Metadata/Parser/Registry.php

<?php declare(strict_types=1);
/*
 * This file is part of PHPUnit.
 *
 * (c) Sebastian Bergmann <sebastian@phpunit.de>
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */
namespace PHPUnit\Metadata\Parser;

/**
 * Attribute and annotation information is static within a single PHP process.
 * It is therefore okay to use a Singleton registry here.
 *
 * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit
 *
 * @internal This class is not covered by the backward compatibility promise for PHPUnit
 */
final class Registry
{
    private static ?Parser $instance = null;

    public static function parser(): Parser
    {
        return self::$instance ?? self::$instance = self::build();
    }

    private static function build(): Parser
    {
        return new CachingParser(
            new ParserChain(
                new AttributeParser,
                new AnnotationParser,
            ),
        );
    }
}

Directory Contents

Dirs: 1 × Files: 6

Name Size Perms Modified Actions
- drwxr-xr-x 2026-01-27 05:48:37
Edit Download
18.87 KB lrw-r--r-- 2026-01-27 05:48:37
Edit Download
24.39 KB lrw-r--r-- 2026-01-27 05:48:37
Edit Download
2.46 KB lrw-r--r-- 2026-01-27 05:48:37
Edit Download
1.07 KB lrw-r--r-- 2026-01-27 05:48:37
Edit Download
2.18 KB lrw-r--r-- 2026-01-27 05:48:37
Edit Download
1.02 KB lrw-r--r-- 2026-01-27 05:48:37
Edit Download

If ZipArchive is unavailable, a .tar will be created (no compression).