| 1 | <?php |
||
| 11 | class Translate implements ApiMethodInterface |
||
| 12 | { |
||
| 13 | /** |
||
| 14 | * @var string |
||
| 15 | */ |
||
| 16 | protected $text; |
||
| 17 | |||
| 18 | /** |
||
| 19 | * @var string |
||
| 20 | */ |
||
| 21 | protected $to; |
||
| 22 | |||
| 23 | /** |
||
| 24 | * @var string|null |
||
| 25 | */ |
||
| 26 | protected $from; |
||
| 27 | |||
| 28 | /** |
||
| 29 | * Translate constructor. |
||
| 30 | * @param $text |
||
| 31 | * @param $to |
||
| 32 | * @param null $from |
||
| 33 | */ |
||
| 34 | 15 | public function __construct($text, $to, $from = null) |
|
| 40 | |||
| 41 | 15 | public function getRequestMethod() |
|
| 45 | |||
| 46 | /** |
||
| 47 | * @return array |
||
| 48 | */ |
||
| 49 | 15 | public function getRequestOptions() |
|
| 59 | |||
| 60 | /** |
||
| 61 | * @param \GuzzleHttp\Message\Response $response |
||
| 62 | * @return string |
||
| 63 | */ |
||
| 64 | 6 | public function processResponse(\GuzzleHttp\Message\Response $response) |
|
| 69 | |||
| 70 | |||
| 71 | } |