OOP/Constructor.pm

filter: Statementstmt 100% 16 / 16 Branchbran n/a Conditioncond 50.0% 2 / 4 MC/DCmcdc 0.0% 0 / 2 Subroutinesub 100% 4 / 4 Podpod 0.0% 0 / 1 totaltotal 81.4% 22 / 27 CC 3 SCAR 7.1
CC
3
Cov
90%
set_args
3.1
BEGIN
1.0
BEGIN
1.0
CRAP 2.0
« OOP.pm ↑ Summary OOP/Accessor.pm »
1 package OOP::Constructor;
2  
3 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 1 ▶use Carp;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 1 ▶use OOP::_getArgs;
Subroutine BEGIN: called CC=1 SCAR=0.0
6  
7 4 ▶sub set_args {
Subroutine set_args: called CC=3 SCAR=11.2
Pod undocumented
8  
9 4 my ($self, $ARGS) = @_;
10  
11 4 ▶ my $arguments = $ARGS->{ARGS} || croak "No arguments were passed to the prototype!";
Condition50%1/2
$ARGS->{'ARGS'} || croak('No arguments were passed to the prototype!')
l!l
40
MC/DC0%0/1
$ARGS->{'ARGS'} || croak('No arguments were passed to the prototype!')
$ARGS->{'ARGS'}
Truth table50%1/2
A
A= $ARGS->{'ARGS'}
Aresult
11
00
12 4 ▶ my $prototype = $ARGS->{PROTOTYPE} || croak "No prototype was passed to the prototype!";
Condition50%1/2
$ARGS->{'PROTOTYPE'} || croak('No prototype was passed to the prototype!')
l!l
40
MC/DC0%0/1
$ARGS->{'PROTOTYPE'} || croak('No prototype was passed to the prototype!')
$ARGS->{'PROTOTYPE'}
Truth table50%1/2
A
A= $ARGS->{'PROTOTYPE'}
Aresult
11
00
13
14 4 my %test;
15  
16 4 tie(%test, 'OOP::_getArgs', {
17 ARGS => $arguments,
18 PROTOTYPE => $prototype
19 });
20  
21 4 return \%test;
22
23 }
24  
25 1 1;
« OOP.pm ↑ Summary OOP/Accessor.pm »