Class/Base.pm

filter: Statementstmt 65.5% 19 / 29 Branchbran n/a Conditioncond 75.0% 3 / 4 MC/DCmcdc 50.0% 1 / 2 Subroutinesub 50.0% 5 / 10 Podpod 16.6% 1 / 6 totaltotal 56.8% 29 / 51 CC 3 SCAR 6.5
CC
3
Cov
67%
new
3.0
build
2.0
is_variable
2.0
CRAP 1.9
« Class/Factory.pm ↑ Summary Class/Method.pm »
1 package PlantUML::ClassDiagram::Class::Base;
2  
3 5 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 5 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 5 ▶use utf8;
Subroutine BEGIN: called CC=1 SCAR=0.0
6  
7 5 ▶use parent qw/Class::Accessor::Fast/;
Subroutine BEGIN: called CC=1 SCAR=0.0
8 5 __PACKAGE__->follow_best_practice;
9  
10 5 my @self_valiables = qw/
11 name
12 attribute
13 /;
14 5 __PACKAGE__->mk_ro_accessors(@self_valiables);
15  
16 8 ▶sub new {
Subroutine new: called CC=3 SCAR=11.1
Pod documented
17 8 my ($class, $name, $attribute) = @_;
18 8 ▶ my $attr = +{
Condition75%3/4
$name || ''
l!l
80
$attribute || ''
l!l
44
MC/DC0%0/1
$name || ''
$name
MC/DC100%1/1
$attribute || ''
$attribute
Truth table50%1/2
A
A= $name
Aresult
11
00
Truth table100%2/2
A
A= $attribute
Aresult
11
00
19 name => $name || '',
20 attribute => $attribute || '',
21 };
22 8 return $class->SUPER::new($attr);
23 }
24  
25 0 ▶sub build {
Subroutine build: not called CC=1 SCAR=6.9
Pod undocumented
26 0 my ($class, $string) = @_;
27  
28 0 my $name = '';
29 0 my $attribute = '';
30  
31 0 return $class->new($name, $attribute);
32 }
33  
34 0 ▶sub is_variable { 0 }
Subroutine is_variable: not called CC=1 SCAR=6.9
Pod undocumented
35 0 ▶sub is_method { 0 }
Subroutine is_method: not called CC=1 SCAR=6.9
Pod undocumented
36  
37 0 ▶sub is_static {
Subroutine is_static: not called CC=1 SCAR=6.9
Pod undocumented
38 0 my ($self) = @_;
39 0 return 0;
40 }
41  
42 0 ▶sub is_abstract {
Subroutine is_abstract: not called CC=1 SCAR=6.9
Pod undocumented
43 0 my ($self) = @_;
44 0 return 0;
45 }
46  
47 5 1;
« Class/Factory.pm ↑ Summary Class/Method.pm »