Passed
Pull Request — master (#14)
by Rimas
02:08
created

PrepareResult   A

Complexity

Total Complexity 9

Size/Duplication

Total Lines 90
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 9
eloc 18
dl 0
loc 90
c 0
b 0
f 0
rs 10

9 Methods

Rating   Name   Duplication   Size   Complexity  
A getDtbs() 0 3 1
A getFields() 0 7 1
A setStatus() 0 3 1
A getDtbsHash() 0 3 1
A setDtbsHash() 0 3 1
A getAlgorithm() 0 3 1
A setAlgorithm() 0 3 1
A setDtbs() 0 3 1
A getStatus() 0 3 1
1
<?php
2
namespace Dokobit\Gateway\Result\Signing;
3
4
use Dokobit\Gateway\Result\ResultInterface;
5
6
/**
7
 * Result object for signing/{token}/prepare response.
8
 */
9
class PrepareResult implements ResultInterface
10
{
11
    /** @var string response status */
12
    private $status;
13
14
    /** @var string dtbs */
15
    private $dtbs;
16
17
    /** @var string dtbs hash */
18
    private $dtbsHash;
19
20
    /** @var string algorithm */
21
    private $algorithm;
22
23
    /**
24
     * Fields expected in response
25
     * @return array
26
     */
27
    public function getFields()
28
    {
29
        return [
30
            'status',
31
            'dtbs',
32
            'dtbs_hash',
33
            'algorithm',
34
        ];
35
    }
36
37
    /**
38
     * Get status
39
     */
40
    public function getStatus(): string
41
    {
42
        return $this->status;
43
    }
44
45
    /**
46
     * Set status
47
     */
48
    public function setStatus(string $status): void
49
    {
50
        $this->status = $status;
51
    }
52
53
    /**
54
     * Get dtbs
55
     */
56
    public function getDtbs(): string
57
    {
58
        return $this->dtbs;
59
    }
60
61
    /**
62
     * Set dtbs
63
     */
64
    public function setDtbs(string $dtbs): void
65
    {
66
        $this->dtbs = $dtbs;
67
    }
68
69
    /**
70
     * Get the value of dtbsHash
71
     */
72
    public function getDtbsHash(): string
73
    {
74
        return $this->dtbsHash;
75
    }
76
77
    /**
78
     * Set the value of dtbsHash
79
     */
80
    public function setDtbsHash(string $dtbsHash): void
81
    {
82
        $this->dtbsHash = $dtbsHash;
83
    }
84
85
    /**
86
     * Get the value of algorithm
87
     */
88
    public function getAlgorithm(): string
89
    {
90
        return $this->algorithm;
91
    }
92
93
    /**
94
     * Set the value of algorithm
95
     */
96
    public function setAlgorithm(string $algorithm): void
97
    {
98
        $this->algorithm = $algorithm;
99
    }
100
}
101