blib/lib/Paws/Net/APIRequest.pm

filter: Statementstmt 100% 26 / 26 Branchbran 100% 2 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 8 / 8 Podpod 0.0% 0 / 2 totaltotal 94.7% 36 / 38 CC 2 SCAR 2.0
CC
2
Cov
100%
header
2.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.2
« lib/Paws/Signin.pm ↑ Summary blib/lib/Paws/Net/FileMockCaller.pm »
1 package Paws::Net::APIRequest;
2 32 ▶ use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
3 32 ▶ use HTTP::Headers;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 32 ▶ use URI;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 434 ▶ has parameters => (is => 'rw', isa => 'HashRef', default => sub { {} });
Subroutine __ANON__: called CC=1 SCAR=0.0
7 434 ▶ has headers => (is => 'rw', isa => 'HTTP::Headers', default => sub { HTTP::Headers->new });
Subroutine __ANON__: called CC=1 SCAR=0.0
8 32 has content => (is => 'rw', isa => 'Str|Undef', default => '');
9 32 has method => (is => 'rw', isa => 'Str');
10 32 has uri => (is => 'rw', isa => 'Str');
11 32 has url => (is => 'rw', isa => 'Str');
12  
13 5654 ▶ sub header {
Subroutine header: called CC=2 SCAR=6.9
Pod undocumented
14 5654 my ($self, $header, $value) = @_;
15 5654 ▶ $self->headers->header($header, $value) if (defined $value);
Branch: 1 branch
BranchTrueFalseTotal
if defined $value 1540 4114 5654
16 5654 return $self->headers->header($header);
17 }
18  
19 20 ▶ sub header_hash {
Subroutine header_hash: called CC=1 SCAR=0.0
Pod undocumented
20 20 my $self = shift;
21 20 my $headers = {};
22 20 ▶ $self->headers->scan(sub { $headers->{ $_[0] } = $_[1] });
Subroutine __ANON__: called CC=1 SCAR=0.0
23 20 return $headers;
24 }
25 32 1;
« lib/Paws/Signin.pm ↑ Summary blib/lib/Paws/Net/FileMockCaller.pm »