ListPaymentOptionsWithVariantsResponse::setCall()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 1
c 1
b 0
f 0
dl 0
loc 3
rs 10
cc 1
nc 1
nop 1
1
<?php
2
3
/**
4
 * PHP version 5.4 and 8
5
 *
6
 * @category  ResponseEntity
7
 * @package   Payever\Payments
8
 * @author    payever GmbH <[email protected]>
9
 * @copyright 2017-2021 payever GmbH
10
 * @license   MIT <https://opensource.org/licenses/MIT>
11
 * @link      https://docs.payever.org/shopsystems/api/getting-started
12
 */
13
14
namespace Payever\ExternalIntegration\Payments\Http\ResponseEntity;
15
16
use Payever\ExternalIntegration\Core\Http\ResponseEntity;
17
use Payever\ExternalIntegration\Payments\Http\MessageEntity\ListPaymentOptionsCallEntity;
18
use Payever\ExternalIntegration\Payments\Http\MessageEntity\ListPaymentOptionsVariantsResultEntity;
19
20
/**
21
 * This class represents List Payment Options ResponseInterface Entity
22
 *
23
 * @method array|ListPaymentOptionsVariantsResultEntity[] getResult()
24
 */
25
class ListPaymentOptionsWithVariantsResponse extends ResponseEntity
26
{
27
    /**
28
     * {@inheritdoc}
29
     */
30
    public function setCall($call)
31
    {
32
        $this->call = new ListPaymentOptionsCallEntity($call);
33
    }
34
35
    /**
36
     * {@inheritdoc}
37
     */
38
    public function setResult($result)
39
    {
40
        $this->result = [];
41
42
        foreach ($result as $item) {
43
            $this->result[] = new ListPaymentOptionsVariantsResultEntity($item);
44
        }
45
    }
46
}
47