Biblio::ILL::ISO::Returned - Perl extension for handling ISO 10161 interlibrary loan Returned messages
Version 0.02
Biblio::ILL::ISO::Returned is a derivation of the abstract Biblio::ILL::ISO::ISO object, and handles the Returned message type.
None.
Each of the set_() methods will croak on missing or invalid parameters.
Returned ::= [APPLICATION 10] SEQUENCE { protocol-version-num [0] IMPLICIT INTEGER, -- { -- version-1 (1), -- version-2 (2) -- }, transaction-id [1] IMPLICIT Transaction-Id, service-date-time [2] IMPLICIT Service-Date-Time, requester-id [3] IMPLICIT System-Id OPTIONAL, -- mandatory when using store-and-forward communications -- optional when using connection-oriented communications responder-id [4] IMPLICIT System-Id OPTIONAL, -- mandatory when using store-and-forward communications -- optional when using connection-oriented communications -- DC - 'EXTERNAL' definition (see Supplemental-Item-Description) -- supplemental-item-description [17] IMPLICIT Supplemental-Item-Description OPTIONAL, date-returned [37] IMPLICIT ISO-Date, returned-via [38] Transportation-Mode OPTIONAL, insured-for [39] IMPLICIT Amount OPTIONAL, requester-note [46] ILL-String OPTIONAL, returned-extensions [49] IMPLICIT SEQUENCE OF Extension OPTIONAL }
new()
Base constructor for the class. It just returns a completely empty message object, which you'll need to populate with the various set_() methods, or use the read() method to read a Returned message from a file (followed by a call to from_asn() to turn the read's returned hash into a proper Returned message.
The constructor also initializes the Convert::ASN1 if it hasn't been initialized.
For any example code, assume the following: my $msg = new Biblio::ILL::ISO::Returned;
To read a message from a file, use the following:
my $href = $msg->read("msg_10.returned.ber"); $msg = $msg->from_asn($href);
The from_asn() method turns the hash returned from read() into a proper message-type object.
Sets the protocol version number. Acceptable parameter values are the strings: version-1 version-2
Sets the message's transaction-id. Expects a valid Biblio::ILL::ISO::TransactionId. my $tid = new Biblio::ILL::ISO::TransactionId("PLS","001","", new Biblio::ILL::ISO::SystemId("MWPL")); $msg->set_transaction_id($tid); This is a mandatory field.
Sets the message's service-date-time. Expects a valid Biblio::ILL::ISO::ServiceDateTime. my $dt_this = new Biblio::ILL::ISO::DateTime("20030623","114400"); my $dt_orig = new Biblio::ILL::ISO::DateTime("20030623","114015") my $sdt = new Biblio::ILL::ISO::ServiceDateTime( $dt_this, $dt_orig); $msg->set_service_date_time($sdt); This is a mandatory field.
Sets the message's requester-id. Expects a valid Biblio::ILL::ISO::SystemId. my $reqid = new Biblio::ILL::ISO::SystemId(); $reqid->set_person_name("David A. Christensen"); $msg->set_requester_id($reqid); This is an optional field.
Sets the message's responder-id. Expects a valid Biblio::ILL::ISO::SystemId. my $resid = new Biblio::ILL::ISO::SystemId("MWPL"); $msg->set_responder_id($resid); This is an optional field.
Sets the message's dat-returned. Expects a valid Biblio::ILL::ISO::ISODate or a properly formatted date string (YYYYMMDD). my $dr = new Biblio::ILL::ISO::ISODate("20030814"); $msg->set_date_returned($dr); This is a mandatory field.
Sets the message's returned-via. Expects a valid Biblio::ILL::ISO::TransportationMode. my $rv = new Biblio::ILL::ISO::TransportationMode("Canada Post"); $msg->set_returned_via($rv); This is an optional field.
Sets the message's insured-for. Expects a valid Biblio::ILL::ISO::Amount or a properly formatted amount string. my $ins = new Biblio::ILL::ISO::Amount("123.45"); $msg->set_insured_for($ins); This is an optional field.
Sets the message's requester-note. Expects a simple text string. $msg->set_requester_note("This is a requester note"); This is an optional field.
Biblio::ILL::ISO::ISO Biblio::ILL::ISO::Request Biblio::ILL::ISO::ForwardNotification Biblio::ILL::ISO::Shipped Biblio::ILL::ISO::Answer Biblio::ILL::ISO::ConditionalReply Biblio::ILL::ISO::Cancel Biblio::ILL::ISO::CancelReply Biblio::ILL::ISO::Received Biblio::ILL::ISO::Recall Biblio::ILL::ISO::Returned Biblio::ILL::ISO::CheckedIn Biblio::ILL::ISO::Overdue Biblio::ILL::ISO::Renew Biblio::ILL::ISO::RenewAnswer Biblio::ILL::ISO::Lost Biblio::ILL::ISO::Damaged Biblio::ILL::ISO::Message Biblio::ILL::ISO::StatusQuery Biblio::ILL::ISO::StatusOrErrorReport Biblio::ILL::ISO::Expired
See the README for system design notes.
For more information on Interlibrary Loan standards (ISO 10160/10161), a good place to start is:
http://www.nlc-bnc.ca/iso/ill/main.htm
David Christensen, <DChristensenSPAMLESS@westman.wave.ca>
Copyright 2003 by David Christensen
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install Biblio::ILL::ISO::asn, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Biblio::ILL::ISO::asn
CPAN shell
perl -MCPAN -e shell install Biblio::ILL::ISO::asn
For more information on module installation, please visit the detailed CPAN module installation guide.