| Total Complexity | 6 |
| Total Lines | 45 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 0 | ||
| 1 | <?php |
||
| 13 | final class EditPostRequest extends RequestModel implements ValidatableModelInterface |
||
| 14 | { |
||
| 15 | 1 | public function getId(): int |
|
| 16 | { |
||
| 17 | 1 | return (int)$this->getValue('attributes.id'); |
|
| 18 | } |
||
| 19 | |||
| 20 | 2 | public function getTitle(): string |
|
| 21 | { |
||
| 22 | 2 | return (string)$this->getValue('body.title'); |
|
| 23 | } |
||
| 24 | |||
| 25 | 2 | public function getText(): string |
|
| 28 | } |
||
| 29 | |||
| 30 | 2 | public function getStatus(): PostStatus |
|
| 31 | { |
||
| 32 | 2 | return new PostStatus($this->getValue('body.status')); |
|
| 33 | } |
||
| 34 | |||
| 35 | 3 | public function getRules(): array |
|
| 58 | 3 | }, |
|
| 59 | ], |
||
| 60 | ]; |
||
| 63 |