Command   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 26
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 1

Importance

Changes 0
Metric Value
wmc 2
lcom 1
cbo 1
dl 0
loc 26
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A build() 0 4 1
1
<?php
2
3
namespace ExiftoolReader;
4
5
use ExiftoolReader\Config\Exiftool;
6
7
/**
8
 * Class Command
9
 */
10
class Command
11
{
12
    /**
13
     * @var Exiftool
14
     */
15
    private $config;
16
17
    /**
18
     * Reader constructor.
19
     *
20
     * @param Exiftool $config
21
     */
22
    public function __construct(Exiftool $config)
23
    {
24
        $this->config = $config;
25
    }
26
27
    /**
28
     * @param string $filename
29
     * @return string
30
     */
31
    public function build($filename)
32
    {
33
        return sprintf($this->config->getCommand(), $filename);
34
    }
35
}