line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Biblio::ILL::ISO::AlreadyForwarded; |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
=head1 NAME |
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
Biblio::ILL::ISO::AlreadyForwarded |
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
=cut |
8
|
|
|
|
|
|
|
|
9
|
4
|
|
|
4
|
|
1183
|
use Biblio::ILL::ISO::ILLASNtype; |
|
4
|
|
|
|
|
9
|
|
|
4
|
|
|
|
|
105
|
|
10
|
4
|
|
|
4
|
|
617
|
use Biblio::ILL::ISO::SystemId; |
|
4
|
|
|
|
|
9
|
|
|
4
|
|
|
|
|
96
|
|
11
|
4
|
|
|
4
|
|
668
|
use Biblio::ILL::ISO::SystemAddress; |
|
4
|
|
|
|
|
10
|
|
|
4
|
|
|
|
|
121
|
|
12
|
|
|
|
|
|
|
|
13
|
4
|
|
|
4
|
|
22
|
use Carp; |
|
4
|
|
|
|
|
7
|
|
|
4
|
|
|
|
|
392
|
|
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
=head1 VERSION |
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
Version 0.01 |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
=cut |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
our $VERSION = '0.01'; |
22
|
|
|
|
|
|
|
#--------------------------------------------------------------------------- |
23
|
|
|
|
|
|
|
# Mods |
24
|
|
|
|
|
|
|
# 0.01 - 2003.08.12 - original version |
25
|
|
|
|
|
|
|
#--------------------------------------------------------------------------- |
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
=head1 DESCRIPTION |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
Biblio::ILL::ISO::AlreadyForwarded is a derivation of Biblio::ILL::ISO::ILLASNtype. |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
=head1 USES |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
Biblio::ILL::ISO::SystemId |
34
|
|
|
|
|
|
|
Biblio::ILL::ISO::SystemAddress |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
=head1 USED IN |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
Biblio::ILL::ISO::UserErrorReport |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
=cut |
41
|
|
|
|
|
|
|
|
42
|
4
|
|
|
4
|
|
1964
|
BEGIN{@ISA = qw ( Biblio::ILL::ISO::ILLASNtype );} # inherit from ILLASNtype |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
=head1 FROM THE ASN DEFINITION |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
Already-Forwarded ::= EXPLICIT SEQUENCE { |
47
|
|
|
|
|
|
|
responder-id [0] IMPLICIT System-Id, |
48
|
|
|
|
|
|
|
responder-address [1] IMPLICIT System-Address OPTIONAL |
49
|
|
|
|
|
|
|
} |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
=cut |
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
=head1 METHODS |
54
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
=cut |
56
|
|
|
|
|
|
|
#--------------------------------------------------------------- |
57
|
|
|
|
|
|
|
# |
58
|
|
|
|
|
|
|
#--------------------------------------------------------------- |
59
|
|
|
|
|
|
|
=head1 |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
=head2 new($system_id [, $system_addr]) |
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
Creates a new AlreadyForwarded object. Expects either no parameters, or |
64
|
|
|
|
|
|
|
a valid Biblio::ILL::ISO::SystemId and (optionally) a valid Biblio::ILL::ISO::SystemAddress. |
65
|
|
|
|
|
|
|
|
66
|
|
|
|
|
|
|
=cut |
67
|
|
|
|
|
|
|
sub new { |
68
|
1
|
|
|
1
|
1
|
9
|
my $class = shift; |
69
|
1
|
|
|
|
|
1
|
my $self = {}; |
70
|
|
|
|
|
|
|
|
71
|
1
|
50
|
|
|
|
4
|
if (@_) { |
72
|
1
|
|
|
|
|
1
|
my ($id, $addr) = @_; |
73
|
|
|
|
|
|
|
|
74
|
1
|
50
|
|
|
|
3
|
croak "invalid responder-id" unless (ref($id) eq "Biblio::ILL::ISO::SystemId"); |
75
|
1
|
50
|
|
|
|
3
|
if ($addr) { |
76
|
1
|
50
|
|
|
|
3
|
croak "invalid responder-address" unless (ref($addr) eq "Biblio::ILL::ISO::SystemAddress"); |
77
|
|
|
|
|
|
|
} |
78
|
|
|
|
|
|
|
|
79
|
1
|
|
|
|
|
1
|
$self->{"responder-id"} = $id; |
80
|
1
|
50
|
|
|
|
3
|
$self->{"responder-address"} = $addr if ($addr); |
81
|
|
|
|
|
|
|
} |
82
|
|
|
|
|
|
|
|
83
|
1
|
|
33
|
|
|
5
|
bless($self, ref($class) || $class); |
84
|
1
|
|
|
|
|
2
|
return ($self); |
85
|
|
|
|
|
|
|
} |
86
|
|
|
|
|
|
|
|
87
|
|
|
|
|
|
|
|
88
|
|
|
|
|
|
|
#--------------------------------------------------------------- |
89
|
|
|
|
|
|
|
# |
90
|
|
|
|
|
|
|
#--------------------------------------------------------------- |
91
|
|
|
|
|
|
|
=head1 |
92
|
|
|
|
|
|
|
|
93
|
|
|
|
|
|
|
=head2 set($system_id [, $system_addr]) |
94
|
|
|
|
|
|
|
|
95
|
|
|
|
|
|
|
Sets the object's responder-id (a Biblio::ILL::ISO::SystemId) and (optionally) responder-address |
96
|
|
|
|
|
|
|
(a Biblio::ILL::ISO::SystemAddress). |
97
|
|
|
|
|
|
|
|
98
|
|
|
|
|
|
|
=cut |
99
|
|
|
|
|
|
|
sub set { |
100
|
0
|
|
|
0
|
1
|
|
my $self = shift; |
101
|
|
|
|
|
|
|
|
102
|
0
|
|
|
|
|
|
my ($id, $addr) = @_; |
103
|
|
|
|
|
|
|
|
104
|
0
|
0
|
|
|
|
|
croak "invalid responder-id" unless (ref($id) eq "Biblio::ILL::ISO::SystemId"); |
105
|
0
|
0
|
|
|
|
|
if ($addr) { |
106
|
0
|
0
|
|
|
|
|
croak "invalid responder-address" unless (ref($addr) eq "Biblio::ILL::ISO::SystemAddress"); |
107
|
|
|
|
|
|
|
} |
108
|
|
|
|
|
|
|
|
109
|
0
|
|
|
|
|
|
$self->{"responder-id"} = $id; |
110
|
0
|
0
|
|
|
|
|
$self->{"responder-address"} = $addr if ($addr); |
111
|
|
|
|
|
|
|
|
112
|
0
|
|
|
|
|
|
return; |
113
|
|
|
|
|
|
|
} |
114
|
|
|
|
|
|
|
|
115
|
|
|
|
|
|
|
|
116
|
|
|
|
|
|
|
#--------------------------------------------------------------- |
117
|
|
|
|
|
|
|
# |
118
|
|
|
|
|
|
|
#--------------------------------------------------------------- |
119
|
|
|
|
|
|
|
=head1 |
120
|
|
|
|
|
|
|
|
121
|
|
|
|
|
|
|
=head2 from_asn($href) |
122
|
|
|
|
|
|
|
|
123
|
|
|
|
|
|
|
Given a properly formatted hash, builds the object. |
124
|
|
|
|
|
|
|
|
125
|
|
|
|
|
|
|
=cut |
126
|
|
|
|
|
|
|
sub from_asn { |
127
|
0
|
|
|
0
|
1
|
|
my $self = shift; |
128
|
0
|
|
|
|
|
|
my $href = shift; |
129
|
|
|
|
|
|
|
|
130
|
0
|
|
|
|
|
|
foreach my $k (keys %$href) { |
131
|
|
|
|
|
|
|
#print ref($self) . "...$k\n"; |
132
|
|
|
|
|
|
|
|
133
|
0
|
0
|
|
|
|
|
if ($k =~ /^responder-id$/) { |
|
|
0
|
|
|
|
|
|
134
|
0
|
|
|
|
|
|
$self->{$k} = new Biblio::ILL::ISO::SystemId(); |
135
|
0
|
|
|
|
|
|
$self->{$k}->from_asn($href->{$k}); |
136
|
|
|
|
|
|
|
|
137
|
|
|
|
|
|
|
} elsif ($k =~ /^responder-address$/) { |
138
|
0
|
|
|
|
|
|
$self->{$k} = new Biblio::ILL::ISO::SystemAddress(); |
139
|
0
|
|
|
|
|
|
$self->{$k}->from_asn($href->{$k}); |
140
|
|
|
|
|
|
|
|
141
|
|
|
|
|
|
|
} else { |
142
|
0
|
|
|
|
|
|
croak "invalid " . ref($self) . " element: [$k]"; |
143
|
|
|
|
|
|
|
} |
144
|
|
|
|
|
|
|
|
145
|
|
|
|
|
|
|
} |
146
|
0
|
|
|
|
|
|
return $self; |
147
|
|
|
|
|
|
|
} |
148
|
|
|
|
|
|
|
|
149
|
|
|
|
|
|
|
=head1 SEE ALSO |
150
|
|
|
|
|
|
|
|
151
|
|
|
|
|
|
|
See the README for system design notes. |
152
|
|
|
|
|
|
|
See the parent class(es) for other available methods. |
153
|
|
|
|
|
|
|
|
154
|
|
|
|
|
|
|
For more information on Interlibrary Loan standards (ISO 10160/10161), |
155
|
|
|
|
|
|
|
a good place to start is: |
156
|
|
|
|
|
|
|
|
157
|
|
|
|
|
|
|
http://www.nlc-bnc.ca/iso/ill/main.htm |
158
|
|
|
|
|
|
|
|
159
|
|
|
|
|
|
|
=cut |
160
|
|
|
|
|
|
|
|
161
|
|
|
|
|
|
|
=head1 AUTHOR |
162
|
|
|
|
|
|
|
|
163
|
|
|
|
|
|
|
David Christensen, |
164
|
|
|
|
|
|
|
|
165
|
|
|
|
|
|
|
=cut |
166
|
|
|
|
|
|
|
|
167
|
|
|
|
|
|
|
|
168
|
|
|
|
|
|
|
=head1 COPYRIGHT AND LICENSE |
169
|
|
|
|
|
|
|
|
170
|
|
|
|
|
|
|
Copyright 2003 by David Christensen |
171
|
|
|
|
|
|
|
|
172
|
|
|
|
|
|
|
This library is free software; you can redistribute it and/or modify it |
173
|
|
|
|
|
|
|
under the same terms as Perl itself. |
174
|
|
|
|
|
|
|
|
175
|
|
|
|
|
|
|
=cut |
176
|
|
|
|
|
|
|
|
177
|
|
|
|
|
|
|
1; |