Completed
Push — master ( 114870...d35a30 )
by Žilvinas
03:56
created

ScPrepareResult::getAlgorithm()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
cc 1
eloc 2
nc 1
nop 0
crap 1
1
<?php
2
namespace Isign\Sign;
3
4
use Isign\ResultInterface;
5
6
class ScPrepareResult implements ResultInterface
7
{
8
    /** @var string response status */
9
    private $status;
10
11
    /** @var string signature algorithm */
12
    private $algorithm;
13
14
    /** @var string token for sc sign query */
15
    private $token;
16
17
    /** @var string sha1 hash of data to be signed */
18
    private $dtbsHash;
19
20
    /** @var string Data to be signed */
21
    private $dtbs;
22
23
    /**
24
     * Fields expected in response
25
     * @return array
26
     */
27 5
    public function getFields()
28
    {
29
        return [
30 5
           'status',
31 5
           'algorithm',
32 5
           'token',
33 5
           'dtbs_hash',
34 5
           'dtbs',
35 5
        ];
36
    }
37
38
    /**
39
     * @return string
40
     */
41 1
    public function getStatus()
42
    {
43 1
        return $this->status;
44
    }
45
46
    /**
47
     * @param string $status
48
     */
49 1
    public function setStatus($status)
50
    {
51 1
        $this->status = $status;
52 1
    }
53
54
    /**
55
     * @return string
56
     */
57 1
    public function getDtbs()
58
    {
59 1
        return $this->dtbs;
60
    }
61
62
    /**
63
     * @param string $dtbs
64
     */
65 1
    public function setDtbs($dtbs)
66
    {
67 1
        $this->dtbs = $dtbs;
68 1
    }
69
70
    /**
71
     * @return string
72
     */
73 1
    public function getToken()
74
    {
75 1
        return $this->token;
76
    }
77
78
    /**
79
     * @param string $token
80
     */
81 1
    public function setToken($token)
82
    {
83 1
        $this->token = $token;
84 1
    }
85
 
86
    /**
87
     * Gets the value of algorithm.
88
     * @return mixed
89
     */
90 1
    public function getAlgorithm()
91
    {
92 1
        return $this->algorithm;
93
    }
94
 
95
    /**
96
     * Sets the value of algorithm.
97
     * @param mixed $algorithm the algorithm
98
     * @return void
99
     */
100 1
    public function setAlgorithm($algorithm)
101
    {
102 1
        $this->algorithm = $algorithm;
103 1
    }
104
 
105
    /**
106
     * Gets the value of dtbsHash.
107
     * @return mixed
108
     */
109 1
    public function getDtbsHash()
110
    {
111 1
        return $this->dtbsHash;
112
    }
113
 
114
    /**
115
     * Sets the value of dtbsHash.
116
     * @param mixed $dtbsHash the dtbs hash
117
     * @return void
118
     */
119 1
    public function setDtbsHash($dtbsHash)
120
    {
121 1
        $this->dtbsHash = $dtbsHash;
122 1
    }
123
}
124