Completed
Push — master ( 8ee32e...efc44e )
by Pablo
02:33
created

AbstractFilesExtractorQueryHandler   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 18
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 2
c 0
b 0
f 0
lcom 0
cbo 1
dl 0
loc 18
rs 10
ccs 5
cts 5
cp 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A getFiles() 0 10 2
1
<?php
2
3
namespace PhpGitHooks\Module\Files\Contract\Query;
4
5
use PhpGitHooks\Module\Files\Domain\File;
6
7
abstract class AbstractFilesExtractorQueryHandler
8
{
9
    /**
10
     * @param array $files
11
     *
12
     * @return File[]
13
     */
14 3
    protected function getFiles(array $files)
15
    {
16 3
        $filesEntity = [];
17
18 3
        foreach ($files as $file) {
19 3
            $filesEntity[] = new File($file);
20
        }
21
22 3
        return $filesEntity;
23
    }
24
}
25