line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Text::PDF::Bool; |
2
|
|
|
|
|
|
|
|
3
|
1
|
|
|
1
|
|
3
|
use strict; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
24
|
|
4
|
1
|
|
|
1
|
|
3
|
use vars qw(@ISA); |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
29
|
|
5
|
|
|
|
|
|
|
# no warnings qw(uninitialized); |
6
|
|
|
|
|
|
|
|
7
|
1
|
|
|
1
|
|
302
|
use Text::PDF::String; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
60
|
|
8
|
|
|
|
|
|
|
@ISA = qw(Text::PDF::String); |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
=head1 NAME |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
PDF::Bool - A special form of L which holds the strings |
13
|
|
|
|
|
|
|
B or B |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
=head1 METHODS |
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
=head2 $b->convert($str) |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
Converts a string into the string which will be stored. |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
=cut |
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
sub convert |
24
|
0
|
|
|
0
|
1
|
|
{ return $_[1] eq "true"; } |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
=head2 as_pdf |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
Converts the value to a PDF output form |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
=cut |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
sub as_pdf |
34
|
0
|
0
|
|
0
|
1
|
|
{ $_[0]->{'val'} ? "true" : "false"; } |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
1; |
37
|
|
|
|
|
|
|
|