1 | <?php |
||
6 | class Result |
||
7 | { |
||
8 | /** |
||
9 | * @var boolean |
||
10 | */ |
||
11 | protected $status = null; |
||
12 | |||
13 | /** |
||
14 | * @var array |
||
15 | */ |
||
16 | protected $errorCodes = []; |
||
17 | |||
18 | /** |
||
19 | * @param HttpResponse $httpResponse |
||
20 | */ |
||
21 | public function __construct(HttpResponse $httpResponse = null) |
||
27 | |||
28 | /** |
||
29 | * @param boolean $status |
||
30 | * @return Response |
||
31 | */ |
||
32 | public function setStatus($status) |
||
37 | |||
38 | /** |
||
39 | * @return boolean |
||
40 | */ |
||
41 | public function getStatus() |
||
45 | |||
46 | /** |
||
47 | * @return boolean |
||
48 | */ |
||
49 | public function isValid() |
||
53 | |||
54 | /** |
||
55 | * @param array $errorCodes |
||
56 | * @return Response |
||
57 | */ |
||
58 | public function setErrorCodes($errorCodes) |
||
67 | |||
68 | /** |
||
69 | * @return array |
||
70 | */ |
||
71 | public function getErrorCodes() |
||
75 | |||
76 | /** |
||
77 | * @param HttpResponse $response |
||
78 | * @return Response |
||
79 | */ |
||
80 | public function setFromHttpResponse(HttpResponse $response) |
||
101 | } |
||
102 |