Total Complexity | 7 |
Total Lines | 57 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
7 | class BatchOperation implements \JsonSerializable |
||
8 | { |
||
9 | /** |
||
10 | * @var string |
||
11 | */ |
||
12 | private $method; |
||
13 | |||
14 | /** |
||
15 | * @var string |
||
16 | */ |
||
17 | private $path; |
||
18 | |||
19 | /** |
||
20 | * @var string |
||
21 | */ |
||
22 | private $body; |
||
23 | |||
24 | public function jsonSerialize() |
||
25 | { |
||
26 | return [ |
||
27 | 'method' => $this->getMethod(), |
||
28 | 'path' => $this->getPath(), |
||
29 | 'body' => $this->getBody() |
||
30 | ]; |
||
31 | } |
||
32 | |||
33 | public function getMethod(): string |
||
34 | { |
||
35 | return $this->method; |
||
36 | } |
||
37 | |||
38 | public function setMethod(string $method): BatchOperation |
||
42 | } |
||
43 | |||
44 | public function getPath(): string |
||
45 | { |
||
46 | return $this->path; |
||
47 | } |
||
48 | |||
49 | public function setPath(string $path): BatchOperation |
||
50 | { |
||
51 | $this->path = $path; |
||
52 | return $this; |
||
53 | } |
||
54 | |||
55 | public function getBody(): string |
||
56 | { |
||
57 | return $this->body; |
||
58 | } |
||
59 | |||
60 | public function setBody(string $body): BatchOperation |
||
64 | } |
||
65 | } |
||
66 |