| 1 | package # hide from PAUSE | ||||||||||||||||||||
| 2 | DBIx::Class::CDBICompat::Stringify; | ||||||||||||||||||||
| 3 | |||||||||||||||||||||
| 4 | 2 | ▶ | use strict; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 5 | 2 | ▶ | use warnings; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 6 | |||||||||||||||||||||
| 7 | 2 | ▶ | use Scalar::Util; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 8 | |||||||||||||||||||||
| 9 | use overload | ||||||||||||||||||||
| 10 | 0 | ▶ | '""' => sub { return shift->stringify_self; }, | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.2
Subroutine
__ANON__: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 11 | 2 | fallback => 1; | |||||||||||||||||||
| 12 | |||||||||||||||||||||
| 13 | 0 | ▶ | sub stringify_self { | ||||||||||||||||||
|
Subroutine
stringify_self: not called CC=4 SCAR=30.0
Pod
undocumented
| |||||||||||||||||||||
| 14 | 0 | my $self = shift; | |||||||||||||||||||
| 15 | 0 | my @cols = $self->columns('Stringify'); | |||||||||||||||||||
| 16 | 0 | ▶ | @cols = $self->primary_column unless @cols; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 17 | 0 | ▶ | my $ret = join "/", map { $self->get_column($_) || '' } @cols; | ||||||||||||||||||
|
Condition0%0/2
$self->get_column($_) || ''
MC/DC0%0/1
$self->get_column($_) || ''
$self->get_column($_)
Truth table0%0/2
A
A= $self->get_column($_)
| |||||||||||||||||||||
| 18 | 0 | ▶ | return $ret || ref $self; | ||||||||||||||||||
|
Condition0%0/3
$ret || ref $self
MC/DC0%0/2
$ret || ref $self
$ret
ref $self
Truth table0%0/3
A || B
A= $retB= ref $self
| |||||||||||||||||||||
| 19 | } | ||||||||||||||||||||
| 20 | |||||||||||||||||||||
| 21 | 2 | 1; | |||||||||||||||||||