Scrutinizer GitHub App not installed

We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.

Install GitHub App

Passed
Push — annotations ( 28ae84...6909ee )
by Jérémiah
17:17
created

ConfigProcessor   A

Complexity

Total Complexity 6

Size/Duplication

Total Lines 33
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 1

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 6
lcom 1
cbo 1
dl 0
loc 33
ccs 13
cts 13
cp 1
rs 10
c 0
b 0
f 0

4 Methods

Rating   Name   Duplication   Size   Complexity  
A register() 0 4 1
A __construct() 0 6 2
A getProcessors() 0 4 1
A process() 0 8 2
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Overblog\GraphQLBundle\Definition;
6
7
use Overblog\GraphQLBundle\Definition\ConfigProcessor\ConfigProcessorInterface;
8
9
final class ConfigProcessor implements ConfigProcessorInterface
10
{
11
    /**
12
     * @var ConfigProcessorInterface[]
13
     */
14
    private $processors;
15
16 95
    public function __construct(iterable $processors)
17
    {
18 95
        foreach ($processors as $processor) {
19 95
            $this->register($processor);
20
        }
21 95
    }
22
23 94
    public function getProcessors()
24
    {
25 94
        return $this->processors;
26
    }
27
28 95
    public function register(ConfigProcessorInterface $configProcessor): void
29
    {
30 95
        $this->processors[] = $configProcessor;
31 95
    }
32
33 94
    public function process(LazyConfig $lazyConfig): LazyConfig
34
    {
35 94
        foreach ($this->getProcessors() as $processor) {
36 94
            $lazyConfig = $processor->process($lazyConfig);
37
        }
38
39 94
        return $lazyConfig;
40
    }
41
}
42