marc4j4r 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,184 @@
1
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
2
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
+ <head>
5
+ <meta name="Content-Type" content="text/html; charset=UTF-8" />
6
+ <title>Module: Java::OrgMarc4j::MarcReader</title>
7
+ <link rel="stylesheet" href="../../css/style.css" type="text/css" media="screen" charset="utf-8" />
8
+ <link rel="stylesheet" href="../../css/common.css" type="text/css" media="screen" charset="utf-8" />
9
+
10
+ <script type="text/javascript" charset="utf-8">
11
+ relpath = '../..';
12
+ if (relpath != '') relpath += '/';
13
+ </script>
14
+ <script type="text/javascript" charset="utf-8" src="../../js/jquery.js"></script>
15
+ <script type="text/javascript" charset="utf-8" src="../../js/app.js"></script>
16
+
17
+ </head>
18
+ <body>
19
+ <script type="text/javascript" charset="utf-8">
20
+ if (window.top.frames.main) document.body.className = 'frames';
21
+ </script>
22
+
23
+ <div id="header">
24
+ <div id="menu">
25
+
26
+ <a href="../../_index.html">Index (M)</a> &raquo;
27
+ <span class='title'>Java</span> &raquo; <span class='title'>OrgMarc4j</span>
28
+ &raquo;
29
+ <span class="title">MarcReader</span>
30
+
31
+
32
+ <div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
33
+ </div>
34
+
35
+ <div id="search">
36
+ <a id="class_list_link" href="#">Class List</a>
37
+ <a id="method_list_link" href="#">Method List</a>
38
+ <a id ="file_list_link" href="#">File List</a>
39
+ </div>
40
+
41
+ <div class="clear"></div>
42
+ </div>
43
+
44
+ <iframe id="search_frame"></iframe>
45
+
46
+ <div id="content"><h1>Module: Java::OrgMarc4j::MarcReader
47
+
48
+
49
+ </h1>
50
+
51
+ <dl class="box">
52
+
53
+
54
+
55
+
56
+
57
+ <dt class="r1">Includes:</dt>
58
+ <dd class="r1">Enumerable</dd>
59
+
60
+
61
+
62
+
63
+ <dt class="r2 last">Defined in:</dt>
64
+ <dd class="r2 last">lib/marc4j4r.rb</dd>
65
+
66
+ </dl>
67
+ <div class="clear"></div>
68
+
69
+ <h2>Overview</h2><div class="docstring">
70
+ <div class="discussion">
71
+ <p>
72
+ Re-open the MarcReader interface, define #each and include Enumerable
73
+ </p>
74
+ <p>
75
+ We also automatically call #hashify on the records that stream through
76
+ #each in order to speed up RecordImpl#[] when (a) doing many operations on
77
+ a single record, and (b) we&#8217;re not worried about interleaved tags
78
+ (e.g., a 520 followed by a 510 followed by another 520)
79
+ </p>
80
+
81
+
82
+ </div>
83
+ </div>
84
+ <div class="tags">
85
+
86
+ </div>
87
+
88
+
89
+
90
+ <h2>Instance Method Summary</h2>
91
+
92
+ <ul class="summary">
93
+
94
+ <li class="public ">
95
+ <span class="summary_signature">
96
+
97
+ <a href="#each-instance_method" title="#each (instance method)">- (Object) <strong>each</strong> </a>
98
+
99
+
100
+
101
+ </span>
102
+
103
+
104
+
105
+
106
+
107
+
108
+
109
+ <span class="summary_desc">
110
+ Return the next record, after calling #hashify on it.
111
+
112
+ </span>
113
+
114
+ </li>
115
+
116
+
117
+ </ul>
118
+
119
+
120
+
121
+ <div id="instance_method_details" class="method_details_list">
122
+ <h2>Instance Method Details</h2>
123
+
124
+
125
+ <div class="method_details first">
126
+ <p class="signature first" id="each-instance_method">
127
+
128
+ - (<tt>Object</tt>) <strong>each</strong>
129
+
130
+
131
+
132
+ </p><div class="docstring">
133
+ <div class="discussion">
134
+ <p>
135
+ Return the next record, after calling #hashify on it
136
+ </p>
137
+
138
+
139
+ </div>
140
+ </div>
141
+ <div class="tags">
142
+
143
+ </div><table class="source_code">
144
+ <tr>
145
+ <td>
146
+ <pre class="lines">
147
+
148
+
149
+ 105
150
+ 106
151
+ 107
152
+ 108
153
+ 109
154
+ 110
155
+ 111</pre>
156
+ </td>
157
+ <td>
158
+ <pre class="code"><span class="info file"># File 'lib/marc4j4r.rb', line 105</span>
159
+
160
+ <span class='def def kw'>def</span> <span class='each identifier id'>each</span>
161
+ <span class='while while kw'>while</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='hasNext identifier id'>hasNext</span>
162
+ <span class='r identifier id'>r</span> <span class='assign token'>=</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='next identifier id'>next</span>
163
+ <span class='r identifier id'>r</span><span class='dot token'>.</span><span class='hashify identifier id'>hashify</span>
164
+ <span class='yield yield kw'>yield</span> <span class='r identifier id'>r</span>
165
+ <span class='end end kw'>end</span>
166
+ <span class='end end kw'>end</span>
167
+ </pre>
168
+ </td>
169
+ </tr>
170
+ </table>
171
+ </div>
172
+
173
+ </div>
174
+
175
+ </div>
176
+
177
+ <div id="footer">
178
+ Generated on Sun Feb 14 22:11:53 2010 by
179
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool">yard</a>
180
+ 0.5.3 (ruby-1.8.7).
181
+ </div>
182
+
183
+ </body>
184
+ </html>
@@ -0,0 +1,245 @@
1
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
2
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
+ <head>
5
+ <meta name="Content-Type" content="text/html; charset=UTF-8" />
6
+ <title>Class: MARC4J4R::Reader</title>
7
+ <link rel="stylesheet" href="../css/style.css" type="text/css" media="screen" charset="utf-8" />
8
+ <link rel="stylesheet" href="../css/common.css" type="text/css" media="screen" charset="utf-8" />
9
+
10
+ <script type="text/javascript" charset="utf-8">
11
+ relpath = '..';
12
+ if (relpath != '') relpath += '/';
13
+ </script>
14
+ <script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
15
+ <script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
16
+
17
+ </head>
18
+ <body>
19
+ <script type="text/javascript" charset="utf-8">
20
+ if (window.top.frames.main) document.body.className = 'frames';
21
+ </script>
22
+
23
+ <div id="header">
24
+ <div id="menu">
25
+
26
+ <a href="../_index.html">Index (R)</a> &raquo;
27
+ <span class='title'><a href="../MARC4J4R.html" title="MARC4J4R (module)">MARC4J4R</a></span>
28
+ &raquo;
29
+ <span class="title">Reader</span>
30
+
31
+
32
+ <div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
33
+ </div>
34
+
35
+ <div id="search">
36
+ <a id="class_list_link" href="#">Class List</a>
37
+ <a id="method_list_link" href="#">Method List</a>
38
+ <a id ="file_list_link" href="#">File List</a>
39
+ </div>
40
+
41
+ <div class="clear"></div>
42
+ </div>
43
+
44
+ <iframe id="search_frame"></iframe>
45
+
46
+ <div id="content"><h1>Class: MARC4J4R::Reader
47
+
48
+
49
+ </h1>
50
+
51
+ <dl class="box">
52
+
53
+ <dt class="r1">Inherits:</dt>
54
+ <dd class="r1">
55
+ <span class="inheritName">Object</span>
56
+
57
+ <ul class="fullTree">
58
+ <li>Object</li>
59
+
60
+ <li class="next">MARC4J4R::Reader</li>
61
+
62
+ </ul>
63
+ <a href="#" class="inheritanceTree">show all</a>
64
+
65
+ </dd>
66
+
67
+
68
+
69
+
70
+
71
+
72
+
73
+
74
+ <dt class="r2 last">Defined in:</dt>
75
+ <dd class="r2 last">lib/marc4j4r.rb</dd>
76
+
77
+ </dl>
78
+ <div class="clear"></div>
79
+
80
+
81
+
82
+
83
+ <h2>Class Method Summary</h2>
84
+
85
+ <ul class="summary">
86
+
87
+ <li class="public ">
88
+ <span class="summary_signature">
89
+
90
+ <a href="#newReader-class_method" title="newReader (class method)">+ (Object) <strong>newReader</strong>(input, type = :strictmarc) </a>
91
+
92
+
93
+
94
+ </span>
95
+
96
+
97
+
98
+
99
+
100
+
101
+
102
+ <span class="summary_desc"></span>
103
+
104
+ </li>
105
+
106
+
107
+ </ul>
108
+
109
+ <h2>Instance Method Summary</h2>
110
+
111
+ <ul class="summary">
112
+
113
+ <li class="public ">
114
+ <span class="summary_signature">
115
+
116
+ <a href="#initialize-instance_method" title="#initialize (instance method)">- (Reader) <strong>initialize</strong> </a>
117
+
118
+
119
+
120
+ </span>
121
+
122
+ <span class="note title constructor">constructor</span>
123
+
124
+
125
+
126
+
127
+
128
+
129
+
130
+ <span class="summary_desc">
131
+ A new instance of Reader.
132
+
133
+ </span>
134
+
135
+ </li>
136
+
137
+
138
+ </ul>
139
+ <div id="constructor_details" class="method_details_list">
140
+ <h2>Constructor Details</h2>
141
+
142
+ <div class="method_details first">
143
+ <p class="signature first" id="initialize-instance_method">
144
+
145
+ - (<tt><a href="" title="MARC4J4R::Reader (class)">Reader</a></tt>) <strong>initialize</strong>
146
+
147
+
148
+
149
+ </p><div class="docstring">
150
+ <div class="discussion">
151
+ <p>
152
+ A new instance of Reader
153
+ </p>
154
+
155
+
156
+ </div>
157
+ </div>
158
+ <div class="tags">
159
+
160
+ </div><table class="source_code">
161
+ <tr>
162
+ <td>
163
+ <pre class="lines">
164
+
165
+
166
+ 70
167
+ 71</pre>
168
+ </td>
169
+ <td>
170
+ <pre class="code"><span class="info file"># File 'lib/marc4j4r.rb', line 70</span>
171
+
172
+ <span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span>
173
+ <span class='end end kw'>end</span>
174
+ </pre>
175
+ </td>
176
+ </tr>
177
+ </table>
178
+ </div>
179
+
180
+ </div>
181
+
182
+
183
+ <div id="class_method_details" class="method_details_list">
184
+ <h2>Class Method Details</h2>
185
+
186
+
187
+ <div class="method_details first">
188
+ <p class="signature first" id="newReader-class_method">
189
+
190
+ + (<tt>Object</tt>) <strong>newReader</strong>(input, type = :strictmarc)
191
+
192
+
193
+
194
+ </p><table class="source_code">
195
+ <tr>
196
+ <td>
197
+ <pre class="lines">
198
+
199
+
200
+ 57
201
+ 58
202
+ 59
203
+ 60
204
+ 61
205
+ 62
206
+ 63
207
+ 64
208
+ 65
209
+ 66
210
+ 67
211
+ 68</pre>
212
+ </td>
213
+ <td>
214
+ <pre class="code"><span class="info file"># File 'lib/marc4j4r.rb', line 57</span>
215
+
216
+ <span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='newReader identifier id'>newReader</span><span class='lparen token'>(</span><span class='input identifier id'>input</span><span class='comma token'>,</span> <span class='type identifier id'>type</span> <span class='assign token'>=</span> <span class='symbol val'>:strictmarc</span><span class='rparen token'>)</span>
217
+ <span class='case case kw'>case</span> <span class='type identifier id'>type</span>
218
+ <span class='when when kw'>when</span> <span class='symbol val'>:strictmarc</span>
219
+ <span class='return return kw'>return</span> <span class='Java constant id'>Java</span><span class='colon2 op'>::</span><span class='org identifier id'>org</span><span class='dot token'>.</span><span class='marc4j identifier id'>marc4j</span><span class='dot token'>.</span><span class='MarcStreamReader constant id'>MarcStreamReader</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='input identifier id'>input</span><span class='rparen token'>)</span>
220
+ <span class='when when kw'>when</span> <span class='symbol val'>:permissivemarc</span>
221
+ <span class='return return kw'>return</span> <span class='Java constant id'>Java</span><span class='colon2 op'>::</span><span class='org identifier id'>org</span><span class='dot token'>.</span><span class='marc4j identifier id'>marc4j</span><span class='dot token'>.</span><span class='MarcPermissiveStreamReader constant id'>MarcPermissiveStreamReader</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='input identifier id'>input</span><span class='rparen token'>)</span>
222
+ <span class='when when kw'>when</span> <span class='symbol val'>:marcxml</span>
223
+ <span class='return return kw'>return</span> <span class='Java constant id'>Java</span><span class='colon2 op'>::</span><span class='org identifier id'>org</span><span class='dot token'>.</span><span class='marc4j identifier id'>marc4j</span><span class='dot token'>.</span><span class='MarcXmlReader constant id'>MarcXmlReader</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='input identifier id'>input</span><span class='rparen token'>)</span>
224
+ <span class='else else kw'>else</span>
225
+ <span class='raise identifier id'>raise</span> <span class='ArgumentError constant id'>ArgumentError</span><span class='comma token'>,</span> <span class='string val'>&quot;Reader type must be :strictmarc, :permissivemarc, or :marcxml&quot;</span>
226
+ <span class='end end kw'>end</span>
227
+ <span class='end end kw'>end</span>
228
+ </pre>
229
+ </td>
230
+ </tr>
231
+ </table>
232
+ </div>
233
+
234
+ </div>
235
+
236
+ </div>
237
+
238
+ <div id="footer">
239
+ Generated on Fri Feb 12 15:53:43 2010 by
240
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool">yard</a>
241
+ 0.5.3 (ruby-1.8.7).
242
+ </div>
243
+
244
+ </body>
245
+ </html>