Silki/HTML/FormatText.pm

filter: Statementstmt 100% 21 / 21 Branchbran 100% 2 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 5 / 5 Podpod 0.0% 0 / 2 totaltotal 93.3% 28 / 30 CC 2 SCAR 2.9
CC
2
Cov
100%
a_end
2.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.3
« Silki/Formatter/HTMLToWiki/Table/Cell.pm ↑ Summary Silki/Schema/Domain.pm »
1 package Silki::HTML::FormatText;
2 {
3 3 $Silki::HTML::FormatText::VERSION = '0.29';
4 }
5  
6 3 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
7 3 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 3 ▶use base 'HTML::FormatText';
Subroutine BEGIN: called CC=1 SCAR=0.0
10  
11 # If these subs don't return true, the formatter won't recurse into the node
12 # for text/etc.
13  
14 2 ▶sub a_start {
Subroutine a_start: called CC=1 SCAR=0.0
Pod undocumented
15 2 my $self = shift;
16 2 my $node = shift;
17  
18 2 $self->{uri_for_a} = $node->attr('href');
19  
20 2 return 1;
21 }
22  
23 2 ▶sub a_end {
Subroutine a_end: called CC=2 SCAR=6.9
Pod undocumented
24 2 my $self = shift;
25 2 my $node = shift;
26  
27 $self->out( ' (' . $self->{uri_for_a} . ')' )
28 2 ▶ if $self->{uri_for_a};
Branch: 1 branch
BranchTrueFalseTotal
if $self->{"uri_for_a"} 1 1 2
29  
30 2 delete $self->{uri_for_a};
31  
32 2 return 1;
33 }
34  
35 3 1;
36  
37 # ABSTRACT: A subclass of HTML::FormatText that also handles links
38  
39  
40 __END__
« Silki/Formatter/HTMLToWiki/Table/Cell.pm ↑ Summary Silki/Schema/Domain.pm »