@@ 19-39 (lines=21) @@ | ||
16 | /** |
|
17 | * @author Artem Bondarenko <[email protected]> |
|
18 | */ |
|
19 | final class DeleteAllResponse implements ApiResponse |
|
20 | { |
|
21 | private $message; |
|
22 | ||
23 | final private function __construct() |
|
24 | { |
|
25 | } |
|
26 | ||
27 | public static function create(array $data): self |
|
28 | { |
|
29 | $model = new static(); |
|
30 | $model->message = $data['message'] ?? ''; |
|
31 | ||
32 | return $model; |
|
33 | } |
|
34 | ||
35 | public function getMessage(): string |
|
36 | { |
|
37 | return $this->message; |
|
38 | } |
|
39 | } |
|
40 |
@@ 19-39 (lines=21) @@ | ||
16 | /** |
|
17 | * @author Tobias Nyholm <[email protected]> |
|
18 | */ |
|
19 | final class DeleteResponse implements ApiResponse |
|
20 | { |
|
21 | private $message; |
|
22 | ||
23 | private function __construct() |
|
24 | { |
|
25 | } |
|
26 | ||
27 | public static function create(array $data): self |
|
28 | { |
|
29 | $model = new self(); |
|
30 | $model->message = $data['message'] ?? ''; |
|
31 | ||
32 | return $model; |
|
33 | } |
|
34 | ||
35 | public function getMessage(): string |
|
36 | { |
|
37 | return $this->message; |
|
38 | } |
|
39 | } |
|
40 |
@@ 19-39 (lines=21) @@ | ||
16 | /** |
|
17 | * @author Tobias Nyholm <[email protected]> |
|
18 | */ |
|
19 | final class UpdateResponse implements ApiResponse |
|
20 | { |
|
21 | private $message; |
|
22 | ||
23 | private function __construct() |
|
24 | { |
|
25 | } |
|
26 | ||
27 | public static function create(array $data): self |
|
28 | { |
|
29 | $model = new self(); |
|
30 | $model->message = $data['message'] ?? ''; |
|
31 | ||
32 | return $model; |
|
33 | } |
|
34 | ||
35 | public function getMessage(): string |
|
36 | { |
|
37 | return $this->message; |
|
38 | } |
|
39 | } |
|
40 |