Failed Conditions
Push — master ( 438024...09a02f )
by Sébastien
03:04
created

PresetLoader::getPreset()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
eloc 1
dl 0
loc 3
ccs 0
cts 3
cp 0
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 1
crap 2
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Soluble\MediaTools\Preset;
6
7
class PresetLoader
8
{
9
    /**
10
     * @var PresetLocator
11
     */
12
    private $locator;
13
14
    public function __construct(PresetLocator $locator)
15
    {
16
        $this->locator = $locator;
17
    }
18
19
    /**
20
     * @param string $presetName
21
     *
22
     * @return PresetInterface
23
     */
24
    public function getPreset(string $presetName): PresetInterface
25
    {
26
        return $this->locator->getPreset($presetName);
27
    }
28
}
29