Passed
Push — master ( 3376db...1497f5 )
by Mike
12:25
created

CommandProvider   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 0%

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A provideCommands() 0 6 1
1
<?php
2
3
4
namespace Nexus\DynamicModules\Communication\Provider;
5
6
7
use Nexus\Console\Provider\CommandProviderInterface;
8
use Nexus\DockerClient\Communication\Command\Compose\DockerComposeRmCommand;
9
use Nexus\DockerClient\Communication\Command\Compose\DockerComposeUpCommand;
10
use Nexus\DockerClient\Communication\Command\Exec\DockerExecCommand;
11
use Nexus\DockerClient\Communication\Command\Volume\VolumeCreateCommand;
12
use Nexus\DockerClient\Communication\Command\Volume\VolumeRemoveCommand;
13
use Xervice\Config\XerviceConfig;
14
use Xervice\Core\Config\ConfigInterface;
15
use Xervice\Core\Locator\AbstractWithLocator;
16
17
/**
18
 * @method \Nexus\DynamicModules\CustomCommandFacade getFacade()
19
 */
20
class CommandProvider extends AbstractWithLocator implements CommandProviderInterface
21
{
22
    /**
23
     * @param array $commands
24
     *
25
     * @return array
26
     * @throws \Core\Locator\Dynamic\ServiceNotParseable
27
     * @throws \Xervice\Config\Exception\ConfigNotFound
28
     */
29
    public function provideCommands(array $commands): array
30
    {
31
        return $this->getFacade()->hydrateCommands(
32
            $commands
33
        );
34
    }
35
}