1 | <?php |
||
16 | class ApiClient |
||
17 | { |
||
18 | /** |
||
19 | * @var Client |
||
20 | */ |
||
21 | private $client; |
||
22 | |||
23 | /** |
||
24 | * @var bool |
||
25 | */ |
||
26 | private $extendedMode = false; |
||
27 | |||
28 | /** |
||
29 | * @param Client $client |
||
30 | * @param bool $extendedMode |
||
31 | */ |
||
32 | public function __construct(Client $client, $extendedMode = false) |
||
37 | |||
38 | /** |
||
39 | * Enables extended API responses |
||
40 | */ |
||
41 | public function enableExtendedMode() |
||
45 | |||
46 | /** |
||
47 | * Disables extended API responses |
||
48 | */ |
||
49 | public function disableExtendedMode() |
||
53 | |||
54 | /** |
||
55 | * @return bool |
||
56 | */ |
||
57 | public function isExtendedModeEnabled() |
||
61 | |||
62 | /** |
||
63 | * @return Client |
||
64 | */ |
||
65 | public function getClient() |
||
69 | |||
70 | /** |
||
71 | * @param string $method |
||
72 | * @param string $path |
||
73 | * @param array $query |
||
74 | * @param array $postFields |
||
75 | * @param array $files |
||
76 | * @param array $headers |
||
77 | * @return ApiResponse |
||
78 | */ |
||
79 | public function call( |
||
100 | |||
101 | /** |
||
102 | * @return string |
||
103 | */ |
||
104 | private function getAcceptHeader() |
||
110 | } |
||
111 |