Completed
Pull Request — master (#3)
by thomas
17:44
created

Response::getStatuses()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 0
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php
2
3
declare(strict_types=1);
4
5
namespace BitWasp\PinEntry;
6
7
class Response
8
{
9
    /**
10
     * Ok Message is debugging information provided after the OK message.
11
     * @var null|string
12
     */
13
    private $okMsg;
14
15
    /**
16
     * Continuous data stream built up response start to OK
17
     * @var string[]
18
     */
19
    private $data;
20
21
    /**
22
     * Stream of statuses passed back in the response.
23
     * @var array
24
     */
25
    private $statuses;
26
27
    /**
28
     * List of comments returned in the response
29
     * @var string[]
30
     */
31
    private $comments = [];
32
33
    public function __construct(
34
        array $data = [],
35
        array $statuses = [],
36
        array $comments = [],
37
        string $okMsg = null
38
    ) {
39
        $this->data = $data;
40
        $this->statuses = $statuses;
41
        $this->comments = $comments;
42
        $this->okMsg = $okMsg;
43
    }
44
45
    public function getComments(): array
46
    {
47
        return $this->comments;
48
    }
49
50
    public function getData(): array
51
    {
52
        return $this->data;
53
    }
54
55
    public function getStatuses(): array
56
    {
57
        return $this->statuses;
58
    }
59
60
    public function getOkMsg()
61
    {
62
        return $this->okMsg;
63
    }
64
}
65