MailboxOrg/API/Base.pm

filter: Statementstmt 72.0% 31 / 43 Branchbran 0.0% 0 / 6 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 75.0% 9 / 12 Podpod 100% 3 / 3 totaltotal 67.1% 43 / 64 CC 4 SCAR 11.0
CC
4
Cov
63%
auth
6.0
deauth
6.0
search
6.0
CRAP 3.0
« MailboxOrg/API/Videochat.pm ↑ Summary MailboxOrg/API/Blacklist.pm »
1 package API::MailboxOrg::API::Base;
2  
3 # ABSTRACT: MailboxOrg::API::Base
4  
5 # ---
6 # This class is auto-generated by bin/get_mailbox_api.pl
7 # ---
8  
9 2 ▶use v5.24;
Subroutine BEGIN: called CC=1 SCAR=0.0
10  
11 2 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
12 2 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
13  
14 2 ▶use Moo;
Subroutine BEGIN: called CC=1 SCAR=0.0
15 2 ▶use Types::Standard qw(Enum Str Int InstanceOf ArrayRef);
Subroutine BEGIN: called CC=1 SCAR=0.0
16 2 ▶use API::MailboxOrg::Types qw(HashRefRestricted Boolean);
Subroutine BEGIN: called CC=1 SCAR=0.0
17 2 ▶use Params::ValidationCompiler qw(validation_for);
Subroutine BEGIN: called CC=1 SCAR=0.0
18  
19 2 extends 'API::MailboxOrg::APIBase';
20  
21 2 with 'MooX::Singleton';
22  
23 2 ▶use feature 'signatures';
Subroutine BEGIN: called CC=1 SCAR=0.0
24 2 ▶no warnings 'experimental::signatures';
Subroutine BEGIN: called CC=1 SCAR=0.0
25  
26 2 our $VERSION = '1.0.2'; # VERSION
27  
28 2 my %validators = (
29 'auth' => validation_for(
30 params => {
31 user => { type => Str, optional => 0 },
32 pass => { type => Str, optional => 0 },
33  
34 },
35 ),
36 'search' => validation_for(
37 params => {
38 query => { type => Str, optional => 0 },
39  
40 },
41 ),
42  
43 );
44  
45  
46 0 ▶sub auth ($self, %params) {
Subroutine auth: not called CC=2 SCAR=17.9
Pod documented
47 0 my $validator = $validators{'auth'};
48 0 ▶ %params = $validator->(%params) if $validator;
Branch: 1 branch
BranchTrueFalseTotal
if $validator 0 0 0
49  
50 0 my %opt = ();
51  
52 0 return $self->_request( 'auth', \%params, \%opt );
53 }
54  
55 0 ▶sub deauth ($self, %params) {
Subroutine deauth: not called CC=2 SCAR=17.9
Pod documented
56 0 my $validator = $validators{'deauth'};
57 0 ▶ %params = $validator->(%params) if $validator;
Branch: 1 branch
BranchTrueFalseTotal
if $validator 0 0 0
58  
59 0 my %opt = ();
60  
61 0 return $self->_request( 'deauth', \%params, \%opt );
62 }
63  
64 0 ▶sub search ($self, %params) {
Subroutine search: not called CC=2 SCAR=17.9
Pod documented
65 0 my $validator = $validators{'search'};
66 0 ▶ %params = $validator->(%params) if $validator;
Branch: 1 branch
BranchTrueFalseTotal
if $validator 0 0 0
67  
68 0 my %opt = ();
69  
70 0 return $self->_request( 'search', \%params, \%opt );
71 }
72  
73  
74 2 1;
75  
76 __END__
« MailboxOrg/API/Videochat.pm ↑ Summary MailboxOrg/API/Blacklist.pm »