CoreFiles by mySites.guru
KeysetAnalyzerManager.php37 lines, 777 bytes, from Joomla_5.2.2-Stable-Full_Package.zip
Raw History Compare with 5.2.1
md5
2b646da1cd8d55155dbae66913853591
sha1
56da0fdac819f8e584b0375d454649744b049d62
sha256
2d416353cb9536316416ce9fde1ee1e16aca299addaebf4e1ff285c87b138307
<?php

declare(strict_types=1);

namespace Jose\Component\KeyManagement\Analyzer;

use Jose\Component\Core\JWKSet;

class KeysetAnalyzerManager
{
    /**
     * @var KeysetAnalyzer[]
     */
    private array $analyzers = [];

    /**
     * Adds a Keyset Analyzer to the manager.
     */
    public function add(KeysetAnalyzer $analyzer): void
    {
        $this->analyzers[] = $analyzer;
    }

    /**
     * This method will analyze the JWKSet object using all analyzers. It returns a message bag that may contains
     * messages.
     */
    public function analyze(JWKSet $jwkset): MessageBag
    {
        $bag = new MessageBag();
        foreach ($this->analyzers as $analyzer) {
            $analyzer->analyze($jwkset, $bag);
        }

        return $bag;
    }
}

The same content is in 135 releases, Joomla 5.1.0-beta1 to 6.2.1. See them all, or every version of this file.