line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Mojolicious::Plugin::Vparam::DOM; |
2
|
72
|
|
|
72
|
|
1742230
|
use Mojo::Base -strict; |
|
72
|
|
|
|
|
9704
|
|
|
72
|
|
|
|
|
482
|
|
3
|
72
|
|
|
72
|
|
7215
|
use Mojolicious::Plugin::Vparam::Common; |
|
72
|
|
|
|
|
142
|
|
|
72
|
|
|
|
|
2918
|
|
4
|
|
|
|
|
|
|
|
5
|
72
|
|
|
72
|
|
899
|
use Mojo::DOM; |
|
72
|
|
|
|
|
8767
|
|
|
72
|
|
|
|
|
9307
|
|
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
sub parse_dom($) { |
8
|
4
|
|
|
4
|
0
|
132
|
my $str = shift; |
9
|
4
|
50
|
|
|
|
9
|
return undef unless defined $str; |
10
|
4
|
100
|
|
|
|
11
|
return undef unless length $str; |
11
|
|
|
|
|
|
|
|
12
|
3
|
|
|
|
|
5
|
my $dom = eval { Mojo::DOM->new( $str ); }; |
|
3
|
|
|
|
|
14
|
|
13
|
3
|
50
|
0
|
|
|
1462
|
warn $@ and return undef if $@; |
14
|
|
|
|
|
|
|
|
15
|
3
|
|
|
|
|
13
|
return $dom; |
16
|
|
|
|
|
|
|
} |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
sub register { |
19
|
74
|
|
|
74
|
0
|
219
|
my ($class, $self, $app, $conf) = @_; |
20
|
|
|
|
|
|
|
|
21
|
74
|
|
|
|
|
229
|
return; |
22
|
|
|
|
|
|
|
} |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
1; |