| line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
|
1
|
|
|
|
|
|
|
package EBook::Ishmael::PDB::Record; |
|
2
|
17
|
|
|
17
|
|
338
|
use 5.016; |
|
|
17
|
|
|
|
|
70
|
|
|
3
|
|
|
|
|
|
|
our $VERSION = '2.01'; |
|
4
|
17
|
|
|
17
|
|
149
|
use strict; |
|
|
17
|
|
|
|
|
49
|
|
|
|
17
|
|
|
|
|
591
|
|
|
5
|
17
|
|
|
17
|
|
87
|
use warnings; |
|
|
17
|
|
|
|
|
30
|
|
|
|
17
|
|
|
|
|
5128
|
|
|
6
|
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
sub new { |
|
8
|
|
|
|
|
|
|
|
|
9
|
585
|
|
|
585
|
1
|
991
|
my $class = shift; |
|
10
|
585
|
|
|
|
|
885
|
my $data = shift; |
|
11
|
585
|
|
|
|
|
971
|
my $params = shift; |
|
12
|
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
my $self = { |
|
14
|
|
|
|
|
|
|
Data => $data, |
|
15
|
|
|
|
|
|
|
Off => $params->{Offset}, |
|
16
|
|
|
|
|
|
|
Attr => $params->{Attributes}, |
|
17
|
|
|
|
|
|
|
UID => $params->{UID}, |
|
18
|
585
|
|
|
|
|
2449
|
}; |
|
19
|
|
|
|
|
|
|
|
|
20
|
585
|
|
|
|
|
2077
|
return bless $self, $class; |
|
21
|
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
} |
|
23
|
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
sub data { |
|
25
|
|
|
|
|
|
|
|
|
26
|
388
|
|
|
388
|
1
|
649
|
my $self = shift; |
|
27
|
|
|
|
|
|
|
|
|
28
|
388
|
|
|
|
|
1081
|
return $self->{Data}; |
|
29
|
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
} |
|
31
|
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
sub offset { |
|
33
|
|
|
|
|
|
|
|
|
34
|
0
|
|
|
0
|
1
|
|
my $self = shift; |
|
35
|
|
|
|
|
|
|
|
|
36
|
0
|
|
|
|
|
|
return $self->{Off}; |
|
37
|
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
} |
|
39
|
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
sub attributes { |
|
41
|
|
|
|
|
|
|
|
|
42
|
0
|
|
|
0
|
1
|
|
my $self = shift; |
|
43
|
|
|
|
|
|
|
|
|
44
|
0
|
|
|
|
|
|
return $self->{Attr}; |
|
45
|
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
} |
|
47
|
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
sub uid { |
|
49
|
|
|
|
|
|
|
|
|
50
|
0
|
|
|
0
|
1
|
|
my $self = shift; |
|
51
|
|
|
|
|
|
|
|
|
52
|
0
|
|
|
|
|
|
return $self->{UID}; |
|
53
|
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
} |
|
55
|
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
1; |
|
57
|
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
=head1 NAME |
|
59
|
|
|
|
|
|
|
|
|
60
|
|
|
|
|
|
|
EBook::Ishmael::PDB::Record - ishmael PDB record interface |
|
61
|
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
=head1 SYNOPSIS |
|
63
|
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
use EBook::Ishmael::PDB::Record; |
|
65
|
|
|
|
|
|
|
|
|
66
|
|
|
|
|
|
|
my $rec = EBook::Ishmael::PDB::Record->new( |
|
67
|
|
|
|
|
|
|
$data, |
|
68
|
|
|
|
|
|
|
{ |
|
69
|
|
|
|
|
|
|
Offset => $offset, |
|
70
|
|
|
|
|
|
|
Attributes => $attr, |
|
71
|
|
|
|
|
|
|
UID => $uid |
|
72
|
|
|
|
|
|
|
} |
|
73
|
|
|
|
|
|
|
); |
|
74
|
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
=head1 DESCRIPTION |
|
76
|
|
|
|
|
|
|
|
|
77
|
|
|
|
|
|
|
B is a module that provides an interface |
|
78
|
|
|
|
|
|
|
for reading Palm PDB records. For L user documentation, you should |
|
79
|
|
|
|
|
|
|
consult its manual (this is developer documentation). |
|
80
|
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
=head1 METHODS |
|
82
|
|
|
|
|
|
|
|
|
83
|
|
|
|
|
|
|
=head2 $r = EBook::Ishmael::PDB::Record->new($data, $info) |
|
84
|
|
|
|
|
|
|
|
|
85
|
|
|
|
|
|
|
Returns a blessed B object. C<$data> is a |
|
86
|
|
|
|
|
|
|
scalar holding the record's data, C<$info> is a hash ref of the record's info |
|
87
|
|
|
|
|
|
|
data. |
|
88
|
|
|
|
|
|
|
|
|
89
|
|
|
|
|
|
|
=over 4 |
|
90
|
|
|
|
|
|
|
|
|
91
|
|
|
|
|
|
|
=item Off |
|
92
|
|
|
|
|
|
|
|
|
93
|
|
|
|
|
|
|
The record's offset. |
|
94
|
|
|
|
|
|
|
|
|
95
|
|
|
|
|
|
|
=item Attributes |
|
96
|
|
|
|
|
|
|
|
|
97
|
|
|
|
|
|
|
The record's attribute bitfield. |
|
98
|
|
|
|
|
|
|
|
|
99
|
|
|
|
|
|
|
=item UID |
|
100
|
|
|
|
|
|
|
|
|
101
|
|
|
|
|
|
|
The record's UID. |
|
102
|
|
|
|
|
|
|
|
|
103
|
|
|
|
|
|
|
=back |
|
104
|
|
|
|
|
|
|
|
|
105
|
|
|
|
|
|
|
=head2 $d = $r->data() |
|
106
|
|
|
|
|
|
|
|
|
107
|
|
|
|
|
|
|
Returns the record's data. |
|
108
|
|
|
|
|
|
|
|
|
109
|
|
|
|
|
|
|
=head2 $o = $r->offset() |
|
110
|
|
|
|
|
|
|
|
|
111
|
|
|
|
|
|
|
Returns the record's offset. |
|
112
|
|
|
|
|
|
|
|
|
113
|
|
|
|
|
|
|
=head2 $a = $r->attributes() |
|
114
|
|
|
|
|
|
|
|
|
115
|
|
|
|
|
|
|
Returns the record's attribute bitfield. |
|
116
|
|
|
|
|
|
|
|
|
117
|
|
|
|
|
|
|
=head2 $u = $r->uid() |
|
118
|
|
|
|
|
|
|
|
|
119
|
|
|
|
|
|
|
Returns the record's UID. |
|
120
|
|
|
|
|
|
|
|
|
121
|
|
|
|
|
|
|
=head1 AUTHOR |
|
122
|
|
|
|
|
|
|
|
|
123
|
|
|
|
|
|
|
Written by Samuel Young, Esamyoung12788@gmail.comE. |
|
124
|
|
|
|
|
|
|
|
|
125
|
|
|
|
|
|
|
This project's source can be found on its |
|
126
|
|
|
|
|
|
|
L. Comments and pull |
|
127
|
|
|
|
|
|
|
requests are welcome! |
|
128
|
|
|
|
|
|
|
|
|
129
|
|
|
|
|
|
|
=head1 COPYRIGHT |
|
130
|
|
|
|
|
|
|
|
|
131
|
|
|
|
|
|
|
Copyright (C) 2025-2026 Samuel Young |
|
132
|
|
|
|
|
|
|
|
|
133
|
|
|
|
|
|
|
This program is free software: you can redistribute it and/or modify |
|
134
|
|
|
|
|
|
|
it under the terms of the GNU General Public License as published by |
|
135
|
|
|
|
|
|
|
the Free Software Foundation, either version 3 of the License, or |
|
136
|
|
|
|
|
|
|
(at your option) any later version. |
|
137
|
|
|
|
|
|
|
|
|
138
|
|
|
|
|
|
|
=head1 SEE ALSO |
|
139
|
|
|
|
|
|
|
|
|
140
|
|
|
|
|
|
|
L |
|
141
|
|
|
|
|
|
|
|
|
142
|
|
|
|
|
|
|
=cut |