MailboxOrg/API/Domain.pm

filter: Statementstmt 60.7% 31 / 51 Branchbran 0.0% 0 / 10 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 64.2% 9 / 14 Podpod 100% 5 / 5 totaltotal 56.2% 45 / 80 CC 6 SCAR 12.9
CC
6
Cov
51%
add
6.0
del
6.0
get
6.0
CRAP 3.6
« MailboxOrg/API/Account.pm ↑ Summary MailboxOrg/API/Mailinglist.pm »
1 package API::MailboxOrg::API::Domain;
2  
3 # ABSTRACT: MailboxOrg::API::Domain
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 'add' => validation_for(
30 params => {
31 account => { type => Str, optional => 0 },
32 domain => { type => Str, optional => 0 },
33 password => { type => Str, optional => 0 },
34 context_id => { type => Str, optional => 1 },
35 create_new_context_id => { type => Boolean, optional => 1 },
36 memo => { type => Str, optional => 1 },
37  
38 },
39 ),
40 'del' => validation_for(
41 params => {
42 account => { type => Str, optional => 0 },
43 domain => { type => Str, optional => 0 },
44  
45 },
46 ),
47 'get' => validation_for(
48 params => {
49 domain => { type => Str, optional => 0 },
50  
51 },
52 ),
53 'list' => validation_for(
54 params => {
55 account => { type => Str, optional => 0 },
56 filter => { type => Str, optional => 1 },
57  
58 },
59 ),
60 'set' => validation_for(
61 params => {
62 domain => { type => Str, optional => 0 },
63 password => { type => Str, optional => 1 },
64 context_id => { type => Str, optional => 1 },
65 create_new_context_id => { type => Boolean, optional => 1 },
66 memo => { type => Str, optional => 1 },
67  
68 },
69 ),
70  
71 );
72  
73  
74 0 ▶sub add ($self, %params) {
Subroutine add: not called CC=2 SCAR=17.9
Pod documented
75 0 my $validator = $validators{'add'};
76 0 ▶ %params = $validator->(%params) if $validator;
Branch: 1 branch
BranchTrueFalseTotal
if $validator 0 0 0
77  
78 0 my %opt = (needs_auth => 1);
79  
80 0 return $self->_request( 'domain.add', \%params, \%opt );
81 }
82  
83 0 ▶sub del ($self, %params) {
Subroutine del: not called CC=2 SCAR=17.9
Pod documented
84 0 my $validator = $validators{'del'};
85 0 ▶ %params = $validator->(%params) if $validator;
Branch: 1 branch
BranchTrueFalseTotal
if $validator 0 0 0
86  
87 0 my %opt = (needs_auth => 1);
88  
89 0 return $self->_request( 'domain.del', \%params, \%opt );
90 }
91  
92 0 ▶sub get ($self, %params) {
Subroutine get: not called CC=2 SCAR=17.9
Pod documented
93 0 my $validator = $validators{'get'};
94 0 ▶ %params = $validator->(%params) if $validator;
Branch: 1 branch
BranchTrueFalseTotal
if $validator 0 0 0
95  
96 0 my %opt = (needs_auth => 1);
97  
98 0 return $self->_request( 'domain.get', \%params, \%opt );
99 }
100  
101 0 ▶sub list ($self, %params) {
Subroutine list: not called CC=2 SCAR=17.9
Pod documented
102 0 my $validator = $validators{'list'};
103 0 ▶ %params = $validator->(%params) if $validator;
Branch: 1 branch
BranchTrueFalseTotal
if $validator 0 0 0
104  
105 0 my %opt = (needs_auth => 1);
106  
107 0 return $self->_request( 'domain.list', \%params, \%opt );
108 }
109  
110 0 ▶sub set ($self, %params) {
Subroutine set: not called CC=2 SCAR=17.9
Pod documented
111 0 my $validator = $validators{'set'};
112 0 ▶ %params = $validator->(%params) if $validator;
Branch: 1 branch
BranchTrueFalseTotal
if $validator 0 0 0
113  
114 0 my %opt = (needs_auth => 1);
115  
116 0 return $self->_request( 'domain.set', \%params, \%opt );
117 }
118  
119  
120 2 1;
121  
122 __END__
« MailboxOrg/API/Account.pm ↑ Summary MailboxOrg/API/Mailinglist.pm »