XMLRPC/Base64.pm

filter: Statementstmt 94.4% 17 / 18 Branchbran 100% 2 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 83.3% 5 / 6 Podpod 0.0% 0 / 1 totaltotal 88.8% 24 / 27 CC 2 SCAR 2.5
CC
2
Cov
95%
decoded
2.0
BEGIN
1.0
__ANON__
1.0
CRAP 1.3
« XMLRPC.pm ↑ Summary XMLRPC/Message.pm »
1 package Mojo::XMLRPC::Base64;
2  
3 3 ▶use Mojo::Base -base;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 3 ▶use Mojo::Util;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 0 ▶use overload bool => sub {1}, '""' => sub { shift->encoded }, fallback => 1;
Subroutine BEGIN: called CC=1 SCAR=0.1
Subroutine __ANON__: not called CC=1 SCAR=0.1
Subroutine __ANON__: called CC=1 SCAR=0.1
7  
8 3 has 'encoded';
9  
10 2 ▶sub decoded {
Subroutine decoded: called CC=2 SCAR=6.9
Pod undocumented
11 2 my $self = shift;
12 2 ▶ if (@_) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_) 1 1 2
13 1 $self->encoded(Mojo::Util::b64_encode($_[0], ''));
14 1 return $self;
15 }
16 1 return Mojo::Util::b64_decode($self->encoded);
17 }
18  
19 3 1;
20  
« XMLRPC.pm ↑ Summary XMLRPC/Message.pm »