1 | <?php |
||
7 | abstract class AbstractMethodPlugin extends AbstractClient implements MethodPluginInterface |
||
8 | { |
||
9 | /** |
||
10 | * The endpoint. |
||
11 | * |
||
12 | * @var string |
||
13 | */ |
||
14 | private $endpoint; |
||
15 | |||
16 | /** |
||
17 | * @var array |
||
18 | */ |
||
19 | private $parameters = []; |
||
20 | |||
21 | /** |
||
22 | * {@inheritdoc} |
||
23 | */ |
||
24 | |||
25 | /** |
||
26 | * @throws \Http\Client\Exception |
||
27 | * |
||
28 | * @return \Psr\Http\Message\ResponseInterface |
||
29 | */ |
||
30 | public function call() |
||
58 | |||
59 | /** |
||
60 | * {@inheritdoc} |
||
61 | */ |
||
62 | public function withEndPoint(string $endpoint) |
||
68 | |||
69 | /** |
||
70 | * {@inheritdoc} |
||
71 | */ |
||
72 | public function getEndPoint() |
||
76 | |||
77 | /** |
||
78 | * {@inheritdoc} |
||
79 | */ |
||
80 | public function withApiKey(string $apikey) |
||
86 | |||
87 | /** |
||
88 | * {@inheritdoc} |
||
89 | */ |
||
90 | public function withParameters(array $parameters) |
||
96 | |||
97 | /** |
||
98 | * {@inheritdoc} |
||
99 | */ |
||
100 | public function getParameters() |
||
104 | |||
105 | /** |
||
106 | * {@inheritdoc} |
||
107 | */ |
||
108 | public function getMethod() |
||
112 | |||
113 | /** |
||
114 | * @param array $parameters |
||
115 | * |
||
116 | * @return \drupol\Yaroc\Plugin\AbstractMethodPlugin |
||
117 | */ |
||
118 | private function setParameters(array $parameters) |
||
124 | |||
125 | /** |
||
126 | * @param string $endpoint |
||
127 | * |
||
128 | * @return \drupol\Yaroc\Plugin\AbstractMethodPlugin |
||
129 | */ |
||
130 | private function setEndPoint(string $endpoint) |
||
136 | |||
137 | /** |
||
138 | * @param string $apikey |
||
139 | * |
||
140 | * @return \drupol\Yaroc\Plugin\AbstractMethodPlugin |
||
141 | */ |
||
142 | private function setApiKey(string $apikey) |
||
150 | } |
||
151 |