Telegram/ReplyKeyboardRemove.pm

filter: Statementstmt 72.7% 8 / 11 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 50.0% 3 / 6 Podpod 100% 2 / 2 totaltotal 68.4% 13 / 19 SCAR 0.2
CC
1
Cov
73%
remove_keyboard
2.0
selective
2.0
_is_boolean
2.0
CRAP 1.0
« Telegram/ForceReply.pm ↑ Summary Telegram/ChatPhoto.pm »
1 # -*- perl -*-
2 ##----------------------------------------------------------------------------
3 ## Net/API/Telegram/ReplyKeyboardRemove.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::ReplyKeyboardRemove;
15 BEGIN
16 {
17 1 ▶ use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
18 1 ▶ use parent qw( Net::API::Telegram::Generic );
Subroutine BEGIN: called CC=1 SCAR=0.0
19 1 ▶ our( $VERSION ) = '0.1';
Subroutine BEGIN: called CC=1 SCAR=0.0
20 };
21  
22 0 ▶sub remove_keyboard { return( shift->_set_get_scalar( 'remove_keyboard', @_ ) ); }
Subroutine remove_keyboard: not called CC=1 SCAR=6.9
Pod documented
23  
24 0 ▶sub selective { return( shift->_set_get_scalar( 'selective', @_ ) ); }
Subroutine selective: not called CC=1 SCAR=6.9
Pod documented
25  
26 0 ▶sub _is_boolean { return( grep( /^$_[1]$/, qw( remove_keyboard selective ) ) ); }
Subroutine _is_boolean: not called CC=1 SCAR=6.9
27  
28 1 1;
29  
30 __END__
31  
32 =encoding utf-8
33  
34 =head1 NAME
35  
36 Net::API::Telegram::ReplyKeyboardRemove - Upon receiving a message with this object, Telegram clients will remove the current custom keyboard and display the default letter-keyboard
37  
38 =head1 SYNOPSIS
39  
40 my $msg = Net::API::Telegram::ReplyKeyboardRemove->new( %data ) ||
41 die( Net::API::Telegram::ReplyKeyboardRemove->error, "\n" );
42  
43 =head1 DESCRIPTION
44  
45 L<Net::API::Telegram::ReplyKeyboardRemove> is a Telegram Message Object as defined here L<https://core.telegram.org/bots/api#replykeyboardremove>
46  
47 This module has been automatically generated from Telegram API documentation by the script scripts/telegram-doc2perl-methods.pl.
48  
49 =head1 METHODS
50  
51 =over 4
52  
53 =item B<new>( {INIT HASH REF}, %PARAMETERS )
54  
55 B<new>() will create a new object for the package, pass any argument it might receive
56 to the special standard routine B<init> that I<must> exist.
57 Then it returns what returns B<init>().
58  
59 The valid parameters are as follow. Methods available here are also parameters to the B<new> method.
60  
61 =over 8
62  
63 =item * I<verbose>
64  
65 =item * I<debug>
66  
67 =back
68  
69 =item B<remove_keyboard>( True )
70  
71 Requests clients to remove the custom keyboard (user will not be able to summon this keyboard; if you want to hide the keyboard from sight but keep it accessible, use one_time_keyboard in ReplyKeyboardMarkup)
72  
73 =item B<selective>( Boolean )
74  
75 Optional. Use this parameter if you want to remove the keyboard for specific users only. Targets: 1) users that are @mentioned in the text of the Message object; 2) if the bot's message is a reply (has reply_to_message_id), sender of the original message.Example: A user votes in a poll, bot returns confirmation message in reply to the vote and removes the keyboard for that user, while still showing the keyboard with poll options to users who haven't voted yet.
76  
77 =back
78  
79 =head1 COPYRIGHT
80  
81 Copyright (c) 2000-2019 DEGUEST Pte. Ltd.
82  
83 =head1 AUTHOR
84  
85 Jacques Deguest E<lt>F<jack@deguest.jp>E<gt>
86  
87 =head1 SEE ALSO
88  
89 L<Net::API::Telegram>
90  
91 =head1 COPYRIGHT & LICENSE
92  
93 Copyright (c) 2018-2019 DEGUEST Pte. Ltd.
94  
95 You can use, copy, modify and redistribute this package and associated
96 files under the same terms as Perl itself.
97  
98 =cut
99  
« Telegram/ForceReply.pm ↑ Summary Telegram/ChatPhoto.pm »