line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package DTL::Fast::Filters; |
2
|
98
|
|
|
98
|
|
499
|
use strict; use utf8; use warnings FATAL => 'all'; |
|
98
|
|
|
98
|
|
180
|
|
|
98
|
|
|
98
|
|
2412
|
|
|
98
|
|
|
|
|
478
|
|
|
98
|
|
|
|
|
173
|
|
|
98
|
|
|
|
|
486
|
|
|
98
|
|
|
|
|
2555
|
|
|
98
|
|
|
|
|
185
|
|
|
98
|
|
|
|
|
3677
|
|
3
|
|
|
|
|
|
|
|
4
|
98
|
|
|
98
|
|
578
|
use DTL::Fast qw(register_filter); |
|
98
|
|
|
|
|
263
|
|
|
98
|
|
|
|
|
17313
|
|
5
|
|
|
|
|
|
|
# not in Django |
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
# experimental |
8
|
|
|
|
|
|
|
register_filter(qw( |
9
|
|
|
|
|
|
|
numberformat DTL::Fast::Filter::Numberformat |
10
|
|
|
|
|
|
|
reverse DTL::Fast::Filter::Reverse |
11
|
|
|
|
|
|
|
strftime DTL::Fast::Filter::Strftime |
12
|
|
|
|
|
|
|
split DTL::Fast::Filter::Split |
13
|
|
|
|
|
|
|
)); |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
# built in filters |
16
|
|
|
|
|
|
|
register_filter(qw( |
17
|
|
|
|
|
|
|
add DTL::Fast::Filter::Add |
18
|
|
|
|
|
|
|
addslashes DTL::Fast::Filter::Addslashes |
19
|
|
|
|
|
|
|
capfirst DTL::Fast::Filter::Capfirst |
20
|
|
|
|
|
|
|
center DTL::Fast::Filter::Center |
21
|
|
|
|
|
|
|
cut DTL::Fast::Filter::Cut |
22
|
|
|
|
|
|
|
date DTL::Fast::Filter::Date |
23
|
|
|
|
|
|
|
default DTL::Fast::Filter::Default |
24
|
|
|
|
|
|
|
default_if_none DTL::Fast::Filter::DefaultIfNone |
25
|
|
|
|
|
|
|
dictsort DTL::Fast::Filter::Dictsort |
26
|
|
|
|
|
|
|
dictsortreversed DTL::Fast::Filter::Dictsortreversed |
27
|
|
|
|
|
|
|
divisibleby DTL::Fast::Filter::Divisibleby |
28
|
|
|
|
|
|
|
escape DTL::Fast::Filter::Escape |
29
|
|
|
|
|
|
|
escapejs DTL::Fast::Filter::Escapejs |
30
|
|
|
|
|
|
|
filesizeformat DTL::Fast::Filter::Filesizeformat |
31
|
|
|
|
|
|
|
first DTL::Fast::Filter::First |
32
|
|
|
|
|
|
|
floatformat DTL::Fast::Filter::Floatformat |
33
|
|
|
|
|
|
|
force_escape DTL::Fast::Filter::Escape |
34
|
|
|
|
|
|
|
get_digit DTL::Fast::Filter::Getdigit |
35
|
|
|
|
|
|
|
iriencode DTL::Fast::Filter::Iriencode |
36
|
|
|
|
|
|
|
join DTL::Fast::Filter::Join |
37
|
|
|
|
|
|
|
last DTL::Fast::Filter::Last |
38
|
|
|
|
|
|
|
length DTL::Fast::Filter::Length |
39
|
|
|
|
|
|
|
length_is DTL::Fast::Filter::Lengthis |
40
|
|
|
|
|
|
|
linebreaks DTL::Fast::Filter::Linebreaks |
41
|
|
|
|
|
|
|
linebreaksbr DTL::Fast::Filter::Linebreaksbr |
42
|
|
|
|
|
|
|
linenumbers DTL::Fast::Filter::Linenumbers |
43
|
|
|
|
|
|
|
ljust DTL::Fast::Filter::Ljust |
44
|
|
|
|
|
|
|
lower DTL::Fast::Filter::Lower |
45
|
|
|
|
|
|
|
make_list DTL::Fast::Filter::MakeList |
46
|
|
|
|
|
|
|
phone2numeric DTL::Fast::Filter::PhoneToNumeric |
47
|
|
|
|
|
|
|
pluralize DTL::Fast::Filter::Pluralize |
48
|
|
|
|
|
|
|
random DTL::Fast::Filter::Random |
49
|
|
|
|
|
|
|
removetags DTL::Fast::Filter::Removetags |
50
|
|
|
|
|
|
|
rjust DTL::Fast::Filter::Rjust |
51
|
|
|
|
|
|
|
safe DTL::Fast::Filter::Safe |
52
|
|
|
|
|
|
|
safeseq DTL::Fast::Filter::SafeSeq |
53
|
|
|
|
|
|
|
slice DTL::Fast::Filter::Slice |
54
|
|
|
|
|
|
|
slugify DTL::Fast::Filter::Slugify |
55
|
|
|
|
|
|
|
stringformat DTL::Fast::Filter::Stringformat |
56
|
|
|
|
|
|
|
striptags DTL::Fast::Filter::Striptags |
57
|
|
|
|
|
|
|
time DTL::Fast::Filter::Time |
58
|
|
|
|
|
|
|
timesince DTL::Fast::Filter::Timesince |
59
|
|
|
|
|
|
|
timeuntil DTL::Fast::Filter::Timeuntil |
60
|
|
|
|
|
|
|
title DTL::Fast::Filter::Title |
61
|
|
|
|
|
|
|
truncatechars DTL::Fast::Filter::Truncatechars |
62
|
|
|
|
|
|
|
truncatechars_html DTL::Fast::Filter::Truncatecharshtml |
63
|
|
|
|
|
|
|
truncatewords DTL::Fast::Filter::Truncatewords |
64
|
|
|
|
|
|
|
truncatewords_html DTL::Fast::Filter::Truncatewordshtml |
65
|
|
|
|
|
|
|
unordered_list DTL::Fast::Filter::Unorderedlist |
66
|
|
|
|
|
|
|
upper DTL::Fast::Filter::Upper |
67
|
|
|
|
|
|
|
urlencode DTL::Fast::Filter::Urlencode |
68
|
|
|
|
|
|
|
urlize DTL::Fast::Filter::Urlize |
69
|
|
|
|
|
|
|
urlizetrunc DTL::Fast::Filter::Urlizetrunc |
70
|
|
|
|
|
|
|
wordcount DTL::Fast::Filter::Wordcount |
71
|
|
|
|
|
|
|
wordwrap DTL::Fast::Filter::Wordwrap |
72
|
|
|
|
|
|
|
yesno DTL::Fast::Filter::Yesno |
73
|
|
|
|
|
|
|
)); |
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
1; |