AkeneoPimMiddlewareConnectorToProcessFacadeBridge   A
last analyzed

Complexity

Total Complexity 4

Size/Duplication

Total Lines 46
Duplicated Lines 0 %

Importance

Changes 3
Bugs 1 Features 0
Metric Value
eloc 6
c 3
b 1
f 0
dl 0
loc 46
rs 10
wmc 4

4 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 3 1
A validate() 0 3 1
A translate() 0 3 1
A map() 0 3 1
1
<?php
2
3
/**
4
 * Copyright © 2016-present Spryker Systems GmbH. All rights reserved.
5
 * Use of this software requires acceptance of the Evaluation License Agreement. See LICENSE file.
6
 */
7
8
namespace SprykerEco\Zed\AkeneoPimMiddlewareConnector\Dependency\Facade;
9
10
use Generated\Shared\Transfer\MapperConfigTransfer;
0 ignored issues
show
Bug introduced by
The type Generated\Shared\Transfer\MapperConfigTransfer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
11
use Generated\Shared\Transfer\TranslatorConfigTransfer;
0 ignored issues
show
Bug introduced by
The type Generated\Shared\Transfer\TranslatorConfigTransfer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
12
use Generated\Shared\Transfer\ValidatorConfigTransfer;
0 ignored issues
show
Bug introduced by
The type Generated\Shared\Transfer\ValidatorConfigTransfer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
13
14
class AkeneoPimMiddlewareConnectorToProcessFacadeBridge implements AkeneoPimMiddlewareConnectorToProcessFacadeInterface
15
{
16
    /**
17
     * @var \SprykerMiddleware\Zed\Process\Business\ProcessFacadeInterface
0 ignored issues
show
Bug introduced by
The type SprykerMiddleware\Zed\Pr...\ProcessFacadeInterface was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
18
     */
19
    protected $processFacade;
20
21
    /**
22
     * @param \SprykerMiddleware\Zed\Process\Business\ProcessFacadeInterface $processFacade
23
     */
24
    public function __construct($processFacade)
25
    {
26
        $this->processFacade = $processFacade;
27
    }
28
29
    /**
30
     * @param array $payload
31
     * @param \Generated\Shared\Transfer\MapperConfigTransfer $mapperConfigTransfer
32
     *
33
     * @return array
34
     */
35
    public function map(array $payload, MapperConfigTransfer $mapperConfigTransfer): array
36
    {
37
        return $this->processFacade->map($payload, $mapperConfigTransfer);
38
    }
39
40
    /**
41
     * @param array $payload
42
     * @param \Generated\Shared\Transfer\TranslatorConfigTransfer $translatorConfigTransfer
43
     *
44
     * @return array
45
     */
46
    public function translate(array $payload, TranslatorConfigTransfer $translatorConfigTransfer): array
47
    {
48
        return $this->processFacade->translate($payload, $translatorConfigTransfer);
49
    }
50
51
    /**
52
     * @param array $payload
53
     * @param \Generated\Shared\Transfer\ValidatorConfigTransfer $validationConfigTransfer
54
     *
55
     * @return array
56
     */
57
    public function validate(array $payload, ValidatorConfigTransfer $validationConfigTransfer): array
58
    {
59
        return $this->processFacade->validate($payload, $validationConfigTransfer);
60
    }
61
}
62