Passed
Pull Request — master (#45)
by
unknown
03:36
created

ComputopToComputopApiClientBridge   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 33
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 3
eloc 5
c 1
b 0
f 0
dl 0
loc 33
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 3 1
A sendPayPalExpressPrepareRequest() 0 3 1
A sendPayPalExpressCompleteRequest() 0 3 1
1
<?php
2
3
/**
4
 * MIT License
5
 * Use of this software requires acceptance of the Evaluation License Agreement. See LICENSE file.
6
 */
7
8
namespace SprykerEco\Yves\Computop\Dependency\Client;
9
10
use Generated\Shared\Transfer\QuoteTransfer;
0 ignored issues
show
Bug introduced by
The type Generated\Shared\Transfer\QuoteTransfer 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
12
class ComputopToComputopApiClientBridge implements ComputopToComputopApiClientInterface
13
{
14
    /**
15
     * @var \SprykerEco\Client\ComputopApi\ComputopApiClientInterface
16
     */
17
    protected $computopApiClient;
18
19
    /**
20
     * @param \SprykerEco\Client\ComputopApi\ComputopApiClientInterface $computopApiClient
21
     */
22
    public function __construct($computopApiClient)
23
    {
24
        $this->computopApiClient = $computopApiClient;
25
    }
26
27
    /**
28
     * @param \Generated\Shared\Transfer\QuoteTransfer $quoteTransfer
29
     *
30
     * @return \Generated\Shared\Transfer\QuoteTransfer
31
     */
32
    public function sendPayPalExpressPrepareRequest(QuoteTransfer $quoteTransfer): QuoteTransfer
33
    {
34
        return $this->computopApiClient->sendPayPalExpressPrepareRequest($quoteTransfer);
35
    }
36
37
    /**
38
     * @param \Generated\Shared\Transfer\QuoteTransfer $quoteTransfer
39
     *
40
     * @return \Generated\Shared\Transfer\QuoteTransfer
41
     */
42
    public function sendPayPalExpressCompleteRequest(QuoteTransfer $quoteTransfer): QuoteTransfer
43
    {
44
        return $this->computopApiClient->sendPayPalExpressCompleteRequest($quoteTransfer);
45
    }
46
}
47