| 1 | package XML::Atom::Syndication::Util; | ||||||||||||||||||||||||||||
| 2 | 22 | ▶ | use strict; | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 3 | |||||||||||||||||||||||||||||
| 4 | 22 | ▶ | use vars qw( @EXPORT_OK ); | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 5 | 22 | @EXPORT_OK = qw( utf8_off nodelist ); | |||||||||||||||||||||||||||
| 6 | |||||||||||||||||||||||||||||
| 7 | 22 | ▶ | use base qw( Exporter ); | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 8 | |||||||||||||||||||||||||||||
| 9 | 111 | ▶ | sub utf8_off { | ||||||||||||||||||||||||||
|
Subroutine
utf8_off: called CC=3 SCAR=12.0
Pod
undocumented
| |||||||||||||||||||||||||||||
| 10 | 111 | ▶ | if ($] > 5.008 && defined $_[0]) { | ||||||||||||||||||||||||||
|
Branch: 1 branch
Condition33%1/3
$] > "5.008" and defined $_[0]
MC/DC0%0/2
$] > "5.008" and defined $_[0]
$] > "5.008"
defined $_[0]
Truth table33%1/3
A and B
A= $] > "5.008"B= defined $_[0]
| |||||||||||||||||||||||||||||
| 11 | 111 | require Encode; | |||||||||||||||||||||||||||
| 12 | 111 | Encode::_utf8_off($_[0]); | |||||||||||||||||||||||||||
| 13 | } | ||||||||||||||||||||||||||||
| 14 | 111 | $_[0]; | |||||||||||||||||||||||||||
| 15 | } | ||||||||||||||||||||||||||||
| 16 | |||||||||||||||||||||||||||||
| 17 | 234 | ▶ | sub nodelist { | ||||||||||||||||||||||||||
|
Subroutine
nodelist: called CC=2 SCAR=6.9
Pod
undocumented
| |||||||||||||||||||||||||||||
| 18 | 234 | my ($node, $ns, $name) = @_; | |||||||||||||||||||||||||||
| 19 | my @nodes = | ||||||||||||||||||||||||||||
| 20 | 808 | ▶ | grep { ref($_) eq 'XML::Elemental::Element' && $_->name eq "{$ns}$name" } | ||||||||||||||||||||||||||
|
Condition100%3/3
ref $_ eq 'XML::Elemental::Element' && $_->name eq "{$ns}$name"
MC/DC100%2/2
ref $_ eq 'XML::Elemental::Element' && $_->name eq "{$ns}$name"
ref $_ eq 'XML::Elemental::Element'
$_->name eq "{$ns}$name"
Truth table100%3/3
A && B
A= ref $_ eq 'XML::Elemental::Element'B= $_->name eq "{$ns}$name"
| |||||||||||||||||||||||||||||
| 21 | 234 | @{$node->elem->contents}; | |||||||||||||||||||||||||||
| 22 | 234 | @nodes; | |||||||||||||||||||||||||||
| 23 | } | ||||||||||||||||||||||||||||
| 24 | |||||||||||||||||||||||||||||
| 25 | 22 | 1; | |||||||||||||||||||||||||||