line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package MARC::Moose::Parser; |
2
|
|
|
|
|
|
|
# ABSTRACT: A record parser base class |
3
|
|
|
|
|
|
|
$MARC::Moose::Parser::VERSION = '1.0.44'; |
4
|
4
|
|
|
4
|
|
2305
|
use Moose; |
|
4
|
|
|
|
|
9
|
|
|
4
|
|
|
|
|
27
|
|
5
|
4
|
|
|
4
|
|
25940
|
use Modern::Perl; |
|
4
|
|
|
|
|
10
|
|
|
4
|
|
|
|
|
48
|
|
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
# FIXME Experimental. Not used yet. |
8
|
|
|
|
|
|
|
#has converter => ( |
9
|
|
|
|
|
|
|
# is => 'rw', |
10
|
|
|
|
|
|
|
# isa => 'Text::IconvPtr', |
11
|
|
|
|
|
|
|
# default => sub { Text::Iconv->new( "cp857", "utf8" ) } |
12
|
|
|
|
|
|
|
#); |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
has lint => (is => 'rw'); |
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
sub begin { |
20
|
0
|
|
|
0
|
1
|
|
return ""; |
21
|
|
|
|
|
|
|
} |
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
sub end { |
26
|
0
|
|
|
0
|
1
|
|
return ""; |
27
|
|
|
|
|
|
|
} |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
sub parse { |
32
|
0
|
|
|
0
|
1
|
|
return MARC::Moose::Record->new(); |
33
|
|
|
|
|
|
|
}; |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
__PACKAGE__->meta->make_immutable; |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
1; |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
__END__ |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
=pod |
42
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
=encoding UTF-8 |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
=head1 NAME |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
MARC::Moose::Parser - A record parser base class |
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
=head1 VERSION |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
version 1.0.44 |
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
=head1 METHODS |
54
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
=head2 lint |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
A <MARC::Moose::Lint::Checker> which is associated with parsed records. This |
58
|
|
|
|
|
|
|
'lint' object is assigned to each record, so the 'check' method is available |
59
|
|
|
|
|
|
|
for them: C<$record->check()>. |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
=head2 begin |
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
=head2 end |
64
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
=head2 parse |
66
|
|
|
|
|
|
|
|
67
|
|
|
|
|
|
|
Return a MARC::Moose::Record object build from a parsed string |
68
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
=head1 SEE ALSO |
70
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
=over 4 |
72
|
|
|
|
|
|
|
|
73
|
|
|
|
|
|
|
=item * |
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
L<MARC::Moose> |
76
|
|
|
|
|
|
|
|
77
|
|
|
|
|
|
|
=item * |
78
|
|
|
|
|
|
|
|
79
|
|
|
|
|
|
|
L<MARC::Moose::Parser::Isis.pm |
80
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
=item * |
82
|
|
|
|
|
|
|
|
83
|
|
|
|
|
|
|
L<MARC::Moose::Parser::Iso2709.pm |
84
|
|
|
|
|
|
|
|
85
|
|
|
|
|
|
|
=item * |
86
|
|
|
|
|
|
|
|
87
|
|
|
|
|
|
|
L<MARC::Moose::Parser::Legacy.pm |
88
|
|
|
|
|
|
|
|
89
|
|
|
|
|
|
|
=item * |
90
|
|
|
|
|
|
|
|
91
|
|
|
|
|
|
|
L<MARC::Moose::Parser::Marcxml.pm |
92
|
|
|
|
|
|
|
|
93
|
|
|
|
|
|
|
=item * |
94
|
|
|
|
|
|
|
|
95
|
|
|
|
|
|
|
L<MARC::Moose::Parser::MarcxmlSax.pm |
96
|
|
|
|
|
|
|
|
97
|
|
|
|
|
|
|
=item * |
98
|
|
|
|
|
|
|
|
99
|
|
|
|
|
|
|
L<MARC::Moose::Parser::MarcxmlSaxSimple.pm |
100
|
|
|
|
|
|
|
|
101
|
|
|
|
|
|
|
=item * |
102
|
|
|
|
|
|
|
|
103
|
|
|
|
|
|
|
L<MARC::Moose::Parser::Yaml.pm |
104
|
|
|
|
|
|
|
|
105
|
|
|
|
|
|
|
=back |
106
|
|
|
|
|
|
|
|
107
|
|
|
|
|
|
|
=head1 AUTHOR |
108
|
|
|
|
|
|
|
|
109
|
|
|
|
|
|
|
Frédéric Demians <f.demians@tamil.fr> |
110
|
|
|
|
|
|
|
|
111
|
|
|
|
|
|
|
=head1 COPYRIGHT AND LICENSE |
112
|
|
|
|
|
|
|
|
113
|
|
|
|
|
|
|
This software is copyright (c) 2021 by Frédéric Demians. |
114
|
|
|
|
|
|
|
|
115
|
|
|
|
|
|
|
This is free software; you can redistribute it and/or modify it under |
116
|
|
|
|
|
|
|
the same terms as the Perl 5 programming language system itself. |
117
|
|
|
|
|
|
|
|
118
|
|
|
|
|
|
|
=cut |