Passed
Pull Request — feature/eco-3656/dev-paypal-ex... (#40)
by
unknown
11:25 queued 06:05
created

PayPalExpressMapper   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 38
Duplicated Lines 0 %

Importance

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

4 Methods

Rating   Name   Duplication   Size   Complexity  
A getComputopResponseTransfer() 0 3 1
A getMethodName() 0 3 1
A getComputopTransfer() 0 3 1
A getPaymentDetailsArray() 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\Zed\Computop\Business\Order\Mapper\PostPlace;
9
10
use Generated\Shared\Transfer\PaymentTransfer;
0 ignored issues
show
Bug introduced by
The type Generated\Shared\Transfer\PaymentTransfer 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 SprykerEco\Shared\Computop\ComputopConfig;
12
use SprykerEco\Zed\Computop\Business\Order\Mapper\MapperInterface;
13
14
class PayPalExpressMapper implements MapperInterface
15
{
16
    /**
17
     * @return string
18
     */
19
    public function getMethodName(): string
20
    {
21
        return ComputopConfig::PAYMENT_METHOD_PAY_PAL_EXPRESS;
22
    }
23
24
    /**
25
     * @param \Generated\Shared\Transfer\PaymentTransfer $paymentTransfer
26
     *
27
     * @return \Generated\Shared\Transfer\ComputopPayPalExpressPaymentTransfer
0 ignored issues
show
Bug introduced by
The type Generated\Shared\Transfe...lExpressPaymentTransfer 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...
28
     */
29
    public function getComputopTransfer(PaymentTransfer $paymentTransfer)
30
    {
31
        return $paymentTransfer->getComputopPayPalExpress();
32
    }
33
34
    /**
35
     * @param \Generated\Shared\Transfer\PaymentTransfer $paymentTransfer
36
     *
37
     * @return \Spryker\Shared\Kernel\Transfer\TransferInterface
38
     */
39
    public function getComputopResponseTransfer(PaymentTransfer $paymentTransfer)
40
    {
41
        return $this->getComputopTransfer($paymentTransfer)->getPayPalExpressInitResponse();
42
    }
43
44
    /**
45
     * @param \Generated\Shared\Transfer\PaymentTransfer $paymentTransfer
46
     *
47
     * @return array
48
     */
49
    public function getPaymentDetailsArray(PaymentTransfer $paymentTransfer): array
50
    {
51
        return [];
52
    }
53
}
54