NAME
MARC::Moose::Lint::Processor - Processor to lint iso2709 file
VERSION
version 1.0.15
ATTRIBUTES
lint
A MARC::Moose::Lint::Checker to be used to validate biblio record.
file
The name of the ISO2709 file containing biblio records to control.
cleaner
A MARC::Moose::Formater which transform a MARC::Moose::Record into another MARC::Moose::Record. Using a cleaner, it's possible to clean biblio records before validating them.
SYNOPSYS
package PeterCleaner;
use Moose;
extends 'MARC::Moose::Formater';
override 'format' => sub {
my ($self, $record) = @_;
for my $field (@{$record->fields}) {
# clean content
}
return $record;
};
package Main;
my $processor = MARC::Moose::Lint::Processor->new(
lint => MARC::Moose::Lint::Checker->new( file => 'unimarc.rules',
file => 'biblio.mrc',
cleaner => PeterCleaner->new(),
verbose => 1,
};
$processor->run();
The above script validates an ISO2709 file named biblio.mrc
on a rules file named unimarc.rules
. As a result, 3 files are created: (1) biblio.mrc.ok
, an ISO2709 containing biblio records complying to the rules, (2) biblio.mrc.bad
containing biblios violating the rules, and (3) biblio.mrc.log
containing a textual representation of biblio records violating the rules + a description of violated rules.
SEE ALSO
AUTHOR
Frédéric Demians <f.demians@tamil.fr>
COPYRIGHT AND LICENSE
This software is copyright (c) 2014 by Frédéric Demians.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
1 POD Error
The following errors were encountered while parsing the POD:
- Around line 166:
Unterminated L<...> sequence