line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
# -*- perl -*- |
2
|
|
|
|
|
|
|
##---------------------------------------------------------------------------- |
3
|
|
|
|
|
|
|
## Net/API/Telegram/InputMediaDocument.pm |
4
|
|
|
|
|
|
|
## Version 0.1 |
5
|
|
|
|
|
|
|
## Copyright(c) 2019 Jacques Deguest |
6
|
|
|
|
|
|
|
## Author: Jacques Deguest <jack@deguest.jp> |
7
|
|
|
|
|
|
|
## Created 2019/05/29 |
8
|
|
|
|
|
|
|
## Modified 2020/05/20 |
9
|
|
|
|
|
|
|
## All rights reserved. |
10
|
|
|
|
|
|
|
## |
11
|
|
|
|
|
|
|
## This program is free software; you can redistribute it and/or modify it |
12
|
|
|
|
|
|
|
## under the same terms as Perl itself. |
13
|
|
|
|
|
|
|
##---------------------------------------------------------------------------- |
14
|
|
|
|
|
|
|
package Net::API::Telegram::InputMediaDocument; |
15
|
|
|
|
|
|
|
BEGIN |
16
|
|
|
|
|
|
|
{ |
17
|
1
|
|
|
1
|
|
826
|
use strict; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
29
|
|
18
|
1
|
|
|
1
|
|
5
|
use parent qw( Net::API::Telegram::Generic ); |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
4
|
|
19
|
1
|
|
|
1
|
|
145
|
our( $VERSION ) = '0.1'; |
20
|
|
|
|
|
|
|
}; |
21
|
|
|
|
|
|
|
|
22
|
0
|
|
|
0
|
1
|
|
sub caption { return( shift->_set_get_scalar( 'caption', @_ ) ); } |
23
|
|
|
|
|
|
|
|
24
|
0
|
|
|
0
|
1
|
|
sub media { return( shift->_set_get_scalar( 'media', @_ ) ); } |
25
|
|
|
|
|
|
|
|
26
|
0
|
|
|
0
|
1
|
|
sub parse_mode { return( shift->_set_get_scalar( 'parse_mode', @_ ) ); } |
27
|
|
|
|
|
|
|
|
28
|
0
|
|
|
0
|
1
|
|
sub type { return( shift->_set_get_scalar( 'type', @_ ) ); } |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
1; |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
__END__ |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
=encoding utf-8 |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
=head1 NAME |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
Net::API::Telegram::InputMediaDocument - A general file to be sent |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
=head1 SYNOPSIS |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
my $msg = Net::API::Telegram::InputMediaDocument->new( %data ) || |
43
|
|
|
|
|
|
|
die( Net::API::Telegram::InputMediaDocument->error, "\n" ); |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
=head1 DESCRIPTION |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
L<Net::API::Telegram::InputMediaDocument> is a Telegram Message Object as defined here L<https://core.telegram.org/bots/api#inputmediadocument> |
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
This module has been automatically generated from Telegram API documentation by the script scripts/telegram-doc2perl-methods.pl. |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
=head1 METHODS |
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
=over 4 |
54
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
=item B<new>( {INIT HASH REF}, %PARAMETERS ) |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
B<new>() will create a new object for the package, pass any argument it might receive |
58
|
|
|
|
|
|
|
to the special standard routine B<init> that I<must> exist. |
59
|
|
|
|
|
|
|
Then it returns what returns B<init>(). |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
The valid parameters are as follow. Methods available here are also parameters to the B<new> method. |
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
=over 8 |
64
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
=item * I<verbose> |
66
|
|
|
|
|
|
|
|
67
|
|
|
|
|
|
|
=item * I<debug> |
68
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
=back |
70
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
=item B<caption>( String ) |
72
|
|
|
|
|
|
|
|
73
|
|
|
|
|
|
|
Optional. Caption of the document to be sent, 0-1024 characters |
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
=item B<media>( String ) |
76
|
|
|
|
|
|
|
|
77
|
|
|
|
|
|
|
File to send. Pass a file_id to send a file that exists on the Telegram servers (recommended), pass an HTTP URL for Telegram to get a file from the Internet, or pass I<attach://<file_attach_name>> to upload a new one using multipart/form-data under <file_attach_name> name. More info on Sending Files » |
78
|
|
|
|
|
|
|
|
79
|
|
|
|
|
|
|
=item B<parse_mode>( String ) |
80
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
Optional. Send Markdown or HTML, if you want Telegram apps to show bold, italic, fixed-width text or inline URLs in the media caption. |
82
|
|
|
|
|
|
|
|
83
|
|
|
|
|
|
|
=item B<thumb>( InputFile or String ) |
84
|
|
|
|
|
|
|
|
85
|
|
|
|
|
|
|
Optional. Thumbnail of the file sent; can be ignored if thumbnail generation for the file is supported server-side. The thumbnail should be in JPEG format and less than 200 kB in size. A thumbnailâs width and height should not exceed 320. Ignored if the file is not uploaded using multipart/form-data. Thumbnails canât be reused and can be only uploaded as a new file, so you can pass I<attach://<file_attach_name>> if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More info on Sending Files » |
86
|
|
|
|
|
|
|
|
87
|
|
|
|
|
|
|
=item B<type>( String ) |
88
|
|
|
|
|
|
|
|
89
|
|
|
|
|
|
|
Type of the result, must be document |
90
|
|
|
|
|
|
|
|
91
|
|
|
|
|
|
|
=back |
92
|
|
|
|
|
|
|
|
93
|
|
|
|
|
|
|
=head1 COPYRIGHT |
94
|
|
|
|
|
|
|
|
95
|
|
|
|
|
|
|
Copyright (c) 2000-2019 DEGUEST Pte. Ltd. |
96
|
|
|
|
|
|
|
|
97
|
|
|
|
|
|
|
=head1 AUTHOR |
98
|
|
|
|
|
|
|
|
99
|
|
|
|
|
|
|
Jacques Deguest E<lt>F<jack@deguest.jp>E<gt> |
100
|
|
|
|
|
|
|
|
101
|
|
|
|
|
|
|
=head1 SEE ALSO |
102
|
|
|
|
|
|
|
|
103
|
|
|
|
|
|
|
L<Net::API::Telegram> |
104
|
|
|
|
|
|
|
|
105
|
|
|
|
|
|
|
=head1 COPYRIGHT & LICENSE |
106
|
|
|
|
|
|
|
|
107
|
|
|
|
|
|
|
Copyright (c) 2018-2019 DEGUEST Pte. Ltd. |
108
|
|
|
|
|
|
|
|
109
|
|
|
|
|
|
|
You can use, copy, modify and redistribute this package and associated |
110
|
|
|
|
|
|
|
files under the same terms as Perl itself. |
111
|
|
|
|
|
|
|
|
112
|
|
|
|
|
|
|
=cut |
113
|
|
|
|
|
|
|
|