| Total Complexity | 6 |
| Total Lines | 42 |
| Duplicated Lines | 0 % |
| Coverage | 73.32% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 9 | final class AuthorizationStatus |
||
| 10 | { |
||
| 11 | private bool $success; |
||
| 12 | private array $topics; |
||
| 13 | private array $attributes; |
||
| 14 | private ?ResponseInterface $response; |
||
| 15 | |||
| 16 | 3 | public function __construct( |
|
| 17 | bool $success, |
||
| 18 | array $topics, |
||
| 19 | array $attributes = [], |
||
| 20 | ?ResponseInterface $response = null |
||
| 21 | ) { |
||
| 22 | 3 | $this->success = $success; |
|
| 23 | 3 | $this->topics = $topics; |
|
| 24 | 3 | $this->attributes = $attributes; |
|
| 25 | 3 | $this->response = $response; |
|
| 26 | } |
||
| 27 | |||
| 28 | 2 | public function isSuccessful(): bool |
|
| 29 | { |
||
| 30 | 2 | return $this->success; |
|
| 31 | } |
||
| 32 | |||
| 33 | public function getTopics(): array |
||
| 36 | } |
||
| 37 | |||
| 38 | public function getAttributes(): array |
||
| 39 | { |
||
| 40 | return $this->attributes; |
||
| 41 | } |
||
| 42 | |||
| 43 | 3 | public function hasResponse(): bool |
|
| 44 | { |
||
| 45 | 3 | return $this->response !== null; |
|
| 46 | } |
||
| 47 | |||
| 48 | 1 | public function getResponse(): ?ResponseInterface |
|
| 51 | } |
||
| 52 | } |
||
| 53 |