line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Pod::Simple::Role::XHTML::WithLinkMappings; |
2
|
1
|
|
|
1
|
|
96928
|
use Moo::Role; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
7
|
|
3
|
|
|
|
|
|
|
|
4
|
|
|
|
|
|
|
our $VERSION = '0.003001'; |
5
|
|
|
|
|
|
|
$VERSION =~ tr/_//d; |
6
|
|
|
|
|
|
|
|
7
|
1
|
|
|
1
|
|
400
|
use HTML::Entities qw(decode_entities encode_entities); |
|
1
|
|
|
|
|
11
|
|
|
1
|
|
|
|
|
92
|
|
8
|
1
|
|
|
1
|
|
391
|
use URL::Encode qw(url_encode_utf8); |
|
1
|
|
|
|
|
4720
|
|
|
1
|
|
|
|
|
68
|
|
9
|
|
|
|
|
|
|
|
10
|
1
|
|
|
1
|
|
611
|
use namespace::clean; |
|
1
|
|
|
|
|
10773
|
|
|
1
|
|
|
|
|
7
|
|
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
has link_mappings => ( is => 'rw' ); |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
around resolve_pod_page_link => sub { |
15
|
|
|
|
|
|
|
my $orig = shift; |
16
|
|
|
|
|
|
|
my $self = shift; |
17
|
|
|
|
|
|
|
my $module = shift; |
18
|
|
|
|
|
|
|
if (defined $module) { |
19
|
|
|
|
|
|
|
my $link_map = $self->link_mappings || {}; |
20
|
|
|
|
|
|
|
my $link = $link_map->{$module}; |
21
|
|
|
|
|
|
|
$module = $link |
22
|
|
|
|
|
|
|
if defined $link; |
23
|
|
|
|
|
|
|
} |
24
|
|
|
|
|
|
|
$self->$orig($module, @_); |
25
|
|
|
|
|
|
|
}; |
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
1; |
28
|
|
|
|
|
|
|
__END__ |