Completed
Push — master ( 4dc0e8...439184 )
by Hannes
22s queued 18s
created

DefaultDriver::merge()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
nc 1
nop 1
dl 0
loc 4
rs 10
c 0
b 0
f 0
1
<?php
2
3
declare(strict_types = 1);
4
5
namespace iio\libmergepdf\Driver;
6
7
use iio\libmergepdf\Source\SourceInterface;
8
9
final class DefaultDriver implements DriverInterface
10
{
11
    /**
12
     * @var DriverInterface
13
     */
14
    private $wrapped;
15
16
    public function __construct(DriverInterface $wrapped = null)
17
    {
18
        $this->wrapped = $wrapped ?: new Fpdi2Driver;
19
    }
20
21
    public function merge(SourceInterface ...$sources): string
22
    {
23
        return $this->wrapped->merge(...$sources);
24
    }
25
}
26