Completed
Push — master ( 0c2573...0eced7 )
by Dominik
02:01
created

CompletePurchaseResponse   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 20
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 2
lcom 0
cbo 1
dl 0
loc 20
ccs 5
cts 5
cp 1
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A isSuccessful() 0 6 1
A isRedirect() 0 4 1
1
<?php
2
/**
3
 * w-vision
4
 *
5
 * LICENSE
6
 *
7
 * This source file is subject to the MIT License
8
 * For the full copyright and license information, please view the LICENSE.md
9
 * file that are distributed with this source code.
10
 *
11
 * @copyright  Copyright (c) 2016 Woche-Pass AG (http://www.w-vision.ch)
12
 * @license    MIT License
13
 */
14
15
namespace Omnipay\Datatrans\Message;
16
17
/**
18
 * Datatrans Complete Purchase Response
19
 */
20
class CompletePurchaseResponse extends AbstractResponse
21
{
22
    /**
23
     * @return bool
24
     */
25 3
    public function isSuccessful()
26
    {
27 3
        $status = $this->getStatus();
28
29 3
        return $status === 'success';
30
    }
31
32
    /**
33
     * @return bool
34
     */
35 1
    public function isRedirect()
36
    {
37 1
        return false;
38
    }
39
}
40