Total Complexity | 2 |
Total Lines | 34 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 0 |
1 | <?php |
||
18 | class SendPhotoMethod implements HasParseModeVariableInterface |
||
19 | { |
||
20 | use FillFromArrayTrait; |
||
21 | use SendToChatVariablesTrait; |
||
22 | use CaptionVariablesTrait; |
||
23 | |||
24 | /** |
||
25 | * Photo to send. Pass a file_id as String to send a photo that exists on the Telegram servers (recommended), |
||
26 | * pass an HTTP URL as a String for Telegram to get a photo from the Internet, |
||
27 | * or upload a new photo using multipart/form-data. |
||
28 | * |
||
29 | * @var InputFileType|string |
||
30 | */ |
||
31 | public $photo; |
||
32 | |||
33 | /** |
||
34 | * @param int|string $chatId |
||
35 | * @param InputFileType|string $photo |
||
36 | * @param array|null $data |
||
37 | * |
||
38 | * @throws \TgBotApi\BotApiBase\Exception\BadArgumentException |
||
39 | * |
||
40 | * @return SendPhotoMethod |
||
41 | */ |
||
42 | 2 | public static function create($chatId, $photo, array $data = null): SendPhotoMethod |
|
54 |