Failed Conditions
Pull Request — experimental/sf (#3225)
by Kentaro
50:47 queued 42:12
created

PaymentResult::setSuccess()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 6

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
cc 1
nc 1
nop 1
dl 0
loc 6
ccs 0
cts 3
cp 0
crap 2
rs 10
c 0
b 0
f 0
1
<?php
2
3
/*
4
 * This file is part of EC-CUBE
5
 *
6
 * Copyright(c) LOCKON CO.,LTD. All Rights Reserved.
7
 *
8
 * http://www.lockon.co.jp/
9
 *
10
 * For the full copyright and license information, please view the LICENSE
11
 * file that was distributed with this source code.
12
 */
13
14
namespace Eccube\Service\Payment;
15
16
use Symfony\Component\HttpFoundation\Response;
17
18
class PaymentResult
0 ignored issues
show
introduced by
Missing class doc comment
Loading history...
19
{
20
    /**
21
     * @var array
22
     */
23
    private $errors;
24
25
    /**
26
     * @var boolean
27
     */
28
    private $success;
29
30
    /**
31
     * @var Response
32
     */
33
    private $response;
34
35
    /**
36
     * @param boolean $success
37
     *
38
     * @return PaymentResult
39
     */
40
    public function setSuccess($success)
41
    {
42
        $this->success = $success;
43
44
        return $this;
45
    }
46
47
    /**
48
     * @return boolean
49
     */
50 7
    public function isSuccess()
51
    {
52 7
        return true;
53
    }
54
55
    /**
56
     * @return array
57
     */
58
    public function getErrors()
59
    {
60
        return [];
61
    }
62
63
    /**
64
     * @param array $errors
65
     *
66
     * @return PaymentResult
67
     */
68
    public function setErrors(array $errors)
69
    {
70
        $this->errors = $errors;
71
72
        return $this;
73
    }
74
75
    /**
76
     * @param Response $response
77
     *
78
     * @return PaymentResult
79
     */
80
    public function setResponse(Response $response)
81
    {
82
        $this->response = $response;
83
84
        return $this;
85
    }
86
87
    /**
88
     * @return Response
89
     */
90 6
    public function getResponse()
91
    {
92 6
        return $this->response;
93
    }
94
}
95