Completed
Push — master ( 60aec0...f632bc )
by Andreas
12:47 queued 10:41
created

ThreedSecureAuthenticateTransaction   A

Complexity

Total Complexity 5

Size/Duplication

Total Lines 30
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 1

Test Coverage

Coverage 100%

Importance

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

4 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 1
A getPares() 0 4 1
A getTransactionId() 0 4 1
A canCommit() 0 5 2
1
<?php
2
3
namespace Larium\Pay\Transaction;
4
5
class ThreedSecureAuthenticateTransaction implements ThreedSecureAuthenticate
6
{
7
    use Commit;
8
9
    private $pares;
10
11
    private $transactionId;
12
13 1
    public function __construct($pares, $transactionId)
14
    {
15 1
        $this->pares = $pares;
16 1
        $this->transactionId = $transactionId;
17 1
    }
18
19
    public function getPares()
20
    {
21
        return $this->pares;
22
    }
23
24
    public function getTransactionId()
25
    {
26
        return $this->transactionId;
27
    }
28
29
    public function canCommit()
30
    {
31
        return $this->pares
32
            && $this->transactionId;
33
    }
34
}
35