NAME

PICA::SRUSearchParser - Parse a SRU response in XML and extract PICA+ records.

METHODS

new

Creates a new Parser. See PICA::Parser for a description of parameters to define handlers (Field and Record).

parseResponse

Parse an SRU SearchRetrieve Response given as an XML string.

counter

Get the number of read records so far.

empty_counter

Get the number of empty records that have been read so far. By default empty records are not passed to the record handler but counted.

PRIVATE HANDLERS

Do not directly call this methods!

_start_handler

SAX handler for XML start tag. On PICA+ records this calls the start handler of PICA::XMLParser.

_end_handler

SAX handler for XML end tag. On PICA+ records this calls the end handler of PICA::XMLParser.

_char_handler

SAX handler for XML character data. On PICA+ records this calls the character data handler of PICA::XMLParser.

TODO

A method to get the parameters in the header (numberOfRecords, resultSetId...) is needed to get the number of records before actually parsing the result.

Following requests of next records it not implemented yet.

There is no check whether the SRU server supports pica format.

Better error handling would be nice to skip invalid records but parse the rest.

We need test cases.

AUTHOR

Jakob Voss <jakob.voss@gbv.de>

LICENSE

Copyright (C) 2007 by Verbundzentrale Göttingen (VZG) and Jakob Voss

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.8 or, at your option, any later version of Perl 5 you may have available.

Please note that these module s not product of or supported by the employers of the various contributors to the code nor by OCLC PICA.

1 POD Error

The following errors were encountered while parsing the POD:

Around line 173:

Non-ASCII character seen before =encoding in 'Göttingen'. Assuming UTF-8