AfterPayClient   A
last analyzed

Complexity

Total Complexity 5

Size/Duplication

Total Lines 82
Duplicated Lines 0 %

Importance

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

5 Methods

Rating   Name   Duplication   Size   Complexity  
A validateCustomerAddress() 0 5 1
A getAvailableInstallmentPlans() 0 6 1
A lookupCustomer() 0 5 1
A getAvailablePaymentMethods() 0 5 1
A validateBankAccount() 0 6 1
1
<?php
2
3
/**
4
 * MIT License
5
 * For full license information, please view the LICENSE file that was distributed with this source code.
6
 */
7
8
namespace SprykerEco\Client\AfterPay;
9
10
use Generated\Shared\Transfer\AfterPayAvailablePaymentMethodsTransfer;
0 ignored issues
show
Bug introduced by
The type Generated\Shared\Transfe...ePaymentMethodsTransfer 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\AfterPayCustomerLookupRequestTransfer;
0 ignored issues
show
Bug introduced by
The type Generated\Shared\Transfe...erLookupRequestTransfer 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\AfterPayCustomerLookupResponseTransfer;
0 ignored issues
show
Bug introduced by
The type Generated\Shared\Transfe...rLookupResponseTransfer 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
use Generated\Shared\Transfer\AfterPayInstallmentPlansRequestTransfer;
0 ignored issues
show
Bug introduced by
The type Generated\Shared\Transfe...entPlansRequestTransfer 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...
14
use Generated\Shared\Transfer\AfterPayInstallmentPlansResponseTransfer;
0 ignored issues
show
Bug introduced by
The type Generated\Shared\Transfe...ntPlansResponseTransfer 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...
15
use Generated\Shared\Transfer\AfterPayValidateBankAccountRequestTransfer;
0 ignored issues
show
Bug introduced by
The type Generated\Shared\Transfe...kAccountRequestTransfer 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...
16
use Generated\Shared\Transfer\AfterPayValidateBankAccountResponseTransfer;
0 ignored issues
show
Bug introduced by
The type Generated\Shared\Transfe...AccountResponseTransfer 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...
17
use Generated\Shared\Transfer\AfterPayValidateCustomerRequestTransfer;
0 ignored issues
show
Bug introduced by
The type Generated\Shared\Transfe...CustomerRequestTransfer 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
use Generated\Shared\Transfer\AfterPayValidateCustomerResponseTransfer;
0 ignored issues
show
Bug introduced by
The type Generated\Shared\Transfe...ustomerResponseTransfer 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...
19
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...
20
use Spryker\Client\Kernel\AbstractClient;
21
22
/**
23
 * @method \SprykerEco\Client\AfterPay\AfterPayFactory getFactory()
24
 */
25
class AfterPayClient extends AbstractClient implements AfterPayClientInterface
26
{
27
    /**
28
     * {@inheritDoc}
29
     *
30
     * @api
31
     *
32
     * @param \Generated\Shared\Transfer\AfterPayValidateCustomerRequestTransfer $validateCustomerRequestTransfer
33
     *
34
     * @return \Generated\Shared\Transfer\AfterPayValidateCustomerResponseTransfer
35
     */
36
    public function validateCustomerAddress(AfterPayValidateCustomerRequestTransfer $validateCustomerRequestTransfer): AfterPayValidateCustomerResponseTransfer
37
    {
38
        return $this->getFactory()
39
            ->createZedAfterPayStub()
40
            ->validateCustomerAddress($validateCustomerRequestTransfer);
41
    }
42
43
    /**
44
     * {@inheritDoc}
45
     *
46
     * @api
47
     *
48
     * @param \Generated\Shared\Transfer\AfterPayInstallmentPlansRequestTransfer $installmentPlansRequestTransfer
49
     *
50
     * @return \Generated\Shared\Transfer\AfterPayInstallmentPlansResponseTransfer
51
     */
52
    public function getAvailableInstallmentPlans(
53
        AfterPayInstallmentPlansRequestTransfer $installmentPlansRequestTransfer
54
    ): AfterPayInstallmentPlansResponseTransfer {
55
        return $this->getFactory()
56
            ->createZedAfterPayStub()
57
            ->getAvailableInstallmentPlans($installmentPlansRequestTransfer);
58
    }
59
60
    /**
61
     * {@inheritDoc}
62
     *
63
     * @api
64
     *
65
     * @param \Generated\Shared\Transfer\AfterPayCustomerLookupRequestTransfer $customerLookupRequestTransfer
66
     *
67
     * @return \Generated\Shared\Transfer\AfterPayCustomerLookupResponseTransfer
68
     */
69
    public function lookupCustomer(AfterPayCustomerLookupRequestTransfer $customerLookupRequestTransfer): AfterPayCustomerLookupResponseTransfer
70
    {
71
        return $this->getFactory()
72
            ->createZedAfterPayStub()
73
            ->lookupCustomer($customerLookupRequestTransfer);
74
    }
75
76
    /**
77
     * {@inheritDoc}
78
     *
79
     * @api
80
     *
81
     * @param \Generated\Shared\Transfer\AfterPayValidateBankAccountRequestTransfer $bankAccountValidationRequestTransfer
82
     *
83
     * @return \Generated\Shared\Transfer\AfterPayValidateBankAccountResponseTransfer
84
     */
85
    public function validateBankAccount(
86
        AfterPayValidateBankAccountRequestTransfer $bankAccountValidationRequestTransfer
87
    ): AfterPayValidateBankAccountResponseTransfer {
88
        return $this->getFactory()
89
            ->createZedAfterPayStub()
90
            ->validateBankAccount($bankAccountValidationRequestTransfer);
91
    }
92
93
    /**
94
     * {@inheritDoc}
95
     *
96
     * @api
97
     *
98
     * @param \Generated\Shared\Transfer\QuoteTransfer $quoteTransfer
99
     *
100
     * @return \Generated\Shared\Transfer\AfterPayAvailablePaymentMethodsTransfer
101
     */
102
    public function getAvailablePaymentMethods(QuoteTransfer $quoteTransfer): AfterPayAvailablePaymentMethodsTransfer
103
    {
104
        return $this->getFactory()
105
            ->createZedAfterPayStub()
106
            ->getAvailablePaymentMethods($quoteTransfer);
107
    }
108
}
109