JWEDecrypterFactoryFactory   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 10
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
eloc 6
c 1
b 0
f 0
dl 0
loc 10
ccs 5
cts 5
cp 1
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A __invoke() 0 8 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace TMV\JWTModule\DIFactory\Encryption;
6
7
use Jose\Component\Core\AlgorithmManagerFactory;
8
use Jose\Component\Encryption\Compression\CompressionMethodManagerFactory;
9
use Jose\Component\Encryption\JWEDecrypterFactory;
10
use Psr\Container\ContainerInterface;
11
12
class JWEDecrypterFactoryFactory
13
{
14 7
    public function __invoke(ContainerInterface $container): JWEDecrypterFactory
15
    {
16 7
        $algorithmManagerFactory = $container->get(AlgorithmManagerFactory::class);
17 7
        $compressionMethodManagerFactory = $container->get(CompressionMethodManagerFactory::class);
18
19 7
        return new JWEDecrypterFactory(
20 7
            $algorithmManagerFactory,
21
            $compressionMethodManagerFactory
22
        );
23
    }
24
}
25