vCard/ADR.pm

filter: Statementstmt 34.3% 11 / 32 Branchbran 6.2% 1 / 16 Conditioncond 50.0% 1 / 2 MC/DCmcdc 0.0% 0 / 1 Subroutinesub 30.0% 3 / 10 Podpod 0.0% 0 / 8 totaltotal 23.1% 16 / 69 CC 10 SCAR 16.1
CC
10
Cov
26%
country
6.0
poBox
6.0
city
6.0
CRAP 5.0
« vFile.pm ↑ Summary
1  
2 package Net::vCard::ADR;
3  
4 5 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 5 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
6  
7  
8 8 ▶sub new {
Subroutine new: called CC=3 SCAR=11.4
Pod undocumented
9 8 my $class=shift;
10 8 ▶ $class = ref($class) if ref($class);
Branch: 1 branch
BranchTrueFalseTotal
if ref $class 0 8 8
11 8 ▶ my $self=shift || {};
Condition50%1/2
shift() || {}
l!l
80
MC/DC0%0/1
shift() || {}
shift()
Truth table50%1/2
A
A= shift()
Aresult
11
00
12  
13 8 return bless $self, $class;
14  
15 }
16  
17 0 ▶sub country {
Subroutine country: not called CC=2 SCAR=17.9
Pod undocumented
18 0 ▶ if (exists $_[1]) {
Branch: 1 branch
BranchTrueFalseTotal
if (exists $_[1]) 0 0 0
19 0 $_[0]->{'country'}=$_[1];
20 }
21 0 return $_[0]->{'country'};
22 }
23  
24 0 ▶sub poBox {
Subroutine poBox: not called CC=2 SCAR=17.9
Pod undocumented
25 0 ▶ if (exists $_[1]) {
Branch: 1 branch
BranchTrueFalseTotal
if (exists $_[1]) 0 0 0
26 0 $_[0]->{'poBox'}=$_[1];
27 }
28 0 return $_[0]->{'poBox'};
29 }
30  
31 0 ▶sub city {
Subroutine city: not called CC=2 SCAR=17.9
Pod undocumented
32 0 ▶ if (exists $_[1]) {
Branch: 1 branch
BranchTrueFalseTotal
if (exists $_[1]) 0 0 0
33 0 $_[0]->{'city'}=$_[1];
34 }
35 0 return $_[0]->{'city'};
36 }
37  
38 0 ▶sub region {
Subroutine region: not called CC=2 SCAR=17.9
Pod undocumented
39 0 ▶ if (exists $_[1]) {
Branch: 1 branch
BranchTrueFalseTotal
if (exists $_[1]) 0 0 0
40 0 $_[0]->{'region'}=$_[1];
41 }
42 0 return $_[0]->{'region'};
43 }
44  
45 0 ▶sub address {
Subroutine address: not called CC=2 SCAR=17.9
Pod undocumented
46 0 ▶ if (exists $_[1]) {
Branch: 1 branch
BranchTrueFalseTotal
if (exists $_[1]) 0 0 0
47 0 $_[0]->{'address'}=$_[1];
48 }
49 0 return $_[0]->{'address'};
50 }
51  
52 0 ▶sub postalCode {
Subroutine postalCode: not called CC=2 SCAR=17.9
Pod undocumented
53 0 ▶ if (exists $_[1]) {
Branch: 1 branch
BranchTrueFalseTotal
if (exists $_[1]) 0 0 0
54 0 $_[0]->{'postalCode'}=$_[1];
55 }
56 0 return $_[0]->{'postalCode'};
57 }
58  
59 0 ▶sub extendedAddress {
Subroutine extendedAddress: not called CC=2 SCAR=17.9
Pod undocumented
60 0 ▶ if (exists $_[1]) {
Branch: 1 branch
BranchTrueFalseTotal
if (exists $_[1]) 0 0 0
61 0 $_[0]->{'extendedAddress'}=$_[1];
62 }
63 0 return $_[0]->{'extendedAddress'};
64 }
65  
66  
67 5 1;
« vFile.pm ↑ Summary