CouchLike/Sth.pm

filter: Statementstmt 50.0% 11 / 22 Branchbran 0.0% 0 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 50.0% 3 / 6 Podpod 0.0% 0 / 3 totaltotal 42.4% 14 / 33 CC 2 SCAR 10.0
CC
2
Cov
46%
execute
6.0
fetchrow_arrayref
2.0
finish
2.0
CRAP 2.7
« CouchLike/SQLite.pm ↑ Summary CouchLike/IdGenerator.pm »
1 package DBIx::CouchLike::Sth;
2  
3 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 1 ▶use base qw/ Class::Accessor::Fast /;
Subroutine BEGIN: called CC=1 SCAR=0.0
6 1 __PACKAGE__->mk_accessors(qw/ sth sql trace quote /);
7  
8 0 ▶sub execute {
Subroutine execute: not called CC=2 SCAR=17.9
Pod undocumented
9 0 my $self = shift;
10  
11 0 ▶ if ( my $h = $self->{trace} ) {
Branch: 1 branch
BranchTrueFalseTotal
if (my $h = $self->{"trace"}) 0 0 0
12 0 my @params = map { $self->{quote}->($_) } @_;
13 0 my $sql = $self->{sql};
14 0 $sql =~ s/\?/shift @params/eg;
15 0 print $h "TRACE >> $sql\n";
16 }
17 0 $self->{sth}->execute(@_);
18 }
19  
20 0 ▶sub fetchrow_arrayref {
Subroutine fetchrow_arrayref: not called CC=1 SCAR=6.9
Pod undocumented
21 0 shift->{sth}->fetchrow_arrayref(@_);
22 }
23  
24 0 ▶sub finish {
Subroutine finish: not called CC=1 SCAR=6.9
Pod undocumented
25 0 shift->{sth}->finish(@_);
26 }
27  
28 1 1;
« CouchLike/SQLite.pm ↑ Summary CouchLike/IdGenerator.pm »