line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Template::Plugin::StickyQuery; |
2
|
|
|
|
|
|
|
|
3
|
2
|
|
|
2
|
|
114160
|
use strict; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
101
|
|
4
|
2
|
|
|
2
|
|
13
|
use vars qw($VERSION); |
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
145
|
|
5
|
|
|
|
|
|
|
$VERSION = 0.01; |
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
require Template::Plugin::Filter; |
8
|
2
|
|
|
2
|
|
11
|
use base qw(Template::Plugin::Filter); |
|
2
|
|
|
|
|
7
|
|
|
2
|
|
|
|
|
1984
|
|
9
|
|
|
|
|
|
|
|
10
|
2
|
|
|
2
|
|
9558
|
use vars qw($DYNAMIC $FILTER_NAME); |
|
2
|
|
|
|
|
6
|
|
|
2
|
|
|
|
|
114
|
|
11
|
|
|
|
|
|
|
$DYNAMIC = 1; |
12
|
|
|
|
|
|
|
$FILTER_NAME = 'stickyquery'; |
13
|
|
|
|
|
|
|
|
14
|
2
|
|
|
2
|
|
1655
|
use HTML::StickyQuery; |
|
2
|
|
|
|
|
57220
|
|
|
2
|
|
|
|
|
298
|
|
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
sub init { |
17
|
1
|
|
|
1
|
0
|
77
|
my $self = shift; |
18
|
1
|
|
33
|
|
|
21
|
my $name = $self->{_ARGS}->[0] || $FILTER_NAME; |
19
|
1
|
|
|
|
|
10
|
$self->install_filter($name); |
20
|
1
|
|
|
|
|
69
|
return $self; |
21
|
|
|
|
|
|
|
} |
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
sub filter { |
24
|
1
|
|
|
1
|
0
|
107
|
my($self, $text, $args, $config) = @_; |
25
|
1
|
|
|
|
|
5
|
my $sticky = HTML::StickyQuery->new(%$config); |
26
|
1
|
|
|
|
|
100
|
return $sticky->sticky(scalarref => \$text, |
27
|
|
|
|
|
|
|
param => $config->{param}); |
28
|
|
|
|
|
|
|
} |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
1; |
32
|
|
|
|
|
|
|
__END__ |