1
|
|
|
<?php |
2
|
|
|
|
3
|
|
|
namespace TelegramBot\Entities\InlineQuery; |
4
|
|
|
|
5
|
|
|
use TelegramBot\Entities\InlineKeyboard; |
6
|
|
|
use TelegramBot\Entities\InputMessageContent\InputMessageContent; |
7
|
|
|
use TelegramBot\Entities\MessageEntity; |
8
|
|
|
|
9
|
|
|
/** |
10
|
|
|
* Class InlineQueryResultCachedDocument |
11
|
|
|
* |
12
|
|
|
* @link https://core.telegram.org/bots/api#inlinequeryresultcacheddocument |
13
|
|
|
* |
14
|
|
|
* <code> |
15
|
|
|
* $data = [ |
16
|
|
|
* 'id' => '', |
17
|
|
|
* 'title' => '', |
18
|
|
|
* 'document_file_id' => '', |
19
|
|
|
* 'description' => '', |
20
|
|
|
* 'caption' => '', |
21
|
|
|
* 'reply_markup' => <InlineKeyboard>, |
22
|
|
|
* 'input_message_content' => <InputMessageContent>, |
23
|
|
|
* ]; |
24
|
|
|
* </code> |
25
|
|
|
* |
26
|
|
|
* @method string getType() Type of the result, must be document |
27
|
|
|
* @method string getId() Unique identifier for this result, 1-64 bytes |
28
|
|
|
* @method string getTitle() Title for the result |
29
|
|
|
* @method string getDocumentFileId() A valid file identifier for the file |
30
|
|
|
* @method string getDescription() Optional. Short description of the result |
31
|
|
|
* @method string getCaption() Optional. Caption of the document to be sent, 0-200 characters |
32
|
|
|
* @method string getParseMode() Optional. Mode for parsing entities in the document caption |
33
|
|
|
* @method MessageEntity[] getCaptionEntities() Optional. List of special entities that appear in the caption, which can be specified instead of parse_mode |
34
|
|
|
* @method InlineKeyboard getReplyMarkup() Optional. An Inline keyboard attached to the message |
35
|
|
|
* @method InputMessageContent getInputMessageContent() Optional. Content of the message to be sent instead of the file |
36
|
|
|
* |
37
|
|
|
* @method $this setId(string $id) Unique identifier for this result, 1-64 bytes |
38
|
|
|
* @method $this setTitle(string $title) Title for the result |
39
|
|
|
* @method $this setDocumentFileId(string $document_file_id) A valid file identifier for the file |
40
|
|
|
* @method $this setDescription(string $description) Optional. Short description of the result |
41
|
|
|
* @method $this setCaption(string $caption) Optional. Caption of the document to be sent, 0-200 characters |
42
|
|
|
* @method $this setParseMode(string $parse_mode) Optional. Mode for parsing entities in the document caption |
43
|
|
|
* @method $this setCaptionEntities(array $caption_entities) Optional. List of special entities that appear in the caption, which can be specified instead of parse_mode |
44
|
|
|
* @method $this setReplyMarkup(InlineKeyboard $reply_markup) Optional. An Inline keyboard attached to the message |
45
|
|
|
* @method $this setInputMessageContent(InputMessageContent $input_message_content) Optional. Content of the message to be sent instead of the file |
46
|
|
|
*/ |
47
|
|
|
class InlineQueryResultCachedDocument extends InlineEntity implements InlineQueryResult |
48
|
|
|
{ |
49
|
|
|
|
50
|
|
|
/** |
51
|
|
|
* InlineQueryResultCachedDocument constructor |
52
|
|
|
* |
53
|
|
|
* @param array $data |
54
|
|
|
*/ |
55
|
|
|
public function __construct(array $data = []) |
56
|
|
|
{ |
57
|
|
|
$data['type'] = 'document'; |
58
|
|
|
parent::__construct($data); |
59
|
|
|
} |
60
|
|
|
|
61
|
|
|
} |
62
|
|
|
|