trackerific 0.3.5 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/Gemfile +1 -1
- data/README.rdoc +37 -13
- data/VERSION +1 -1
- data/doc/OptionsHelper.html +287 -0
- data/doc/Trackerific.html +588 -35
- data/doc/Trackerific/Configuration.html +354 -0
- data/doc/Trackerific/Details.html +1 -1
- data/doc/Trackerific/Error.html +1 -1
- data/doc/Trackerific/Event.html +1 -1
- data/doc/Trackerific/FedEx.html +52 -35
- data/doc/Trackerific/{Base.html → Service.html} +54 -49
- data/doc/Trackerific/UPS.html +48 -31
- data/doc/Trackerific/USPS.html +51 -34
- data/doc/_index.html +35 -4
- data/doc/class_list.html +1 -1
- data/doc/file.README.html +42 -15
- data/doc/index.html +42 -15
- data/doc/method_list.html +83 -19
- data/doc/top-level-namespace.html +2 -2
- data/lib/helpers/options_helper.rb +20 -0
- data/lib/trackerific.rb +52 -18
- data/lib/trackerific/configuration.rb +49 -0
- data/lib/trackerific/service.rb +68 -0
- data/lib/trackerific/services/fedex.rb +18 -16
- data/lib/trackerific/services/ups.rb +16 -14
- data/lib/trackerific/services/usps.rb +17 -15
- data/spec/lib/trackerific/configuration_spec.rb +9 -0
- data/spec/lib/trackerific/details_spec.rb +12 -9
- data/spec/lib/trackerific/error_spec.rb +6 -2
- data/spec/lib/trackerific/event_spec.rb +21 -8
- data/spec/lib/trackerific/service_spec.rb +34 -0
- data/spec/lib/trackerific/services/fedex_spec.rb +23 -9
- data/spec/lib/trackerific/services/ups_spec.rb +23 -8
- data/spec/lib/trackerific/services/usps_spec.rb +22 -8
- data/spec/lib/trackerific_spec.rb +29 -7
- data/spec/spec_helper.rb +1 -0
- data/spec/support/fixtures.rb +16 -10
- data/spec/support/trackerific.rb +2 -2
- data/trackerific.gemspec +13 -8
- metadata +30 -25
- data/lib/trackerific/base.rb +0 -70
- data/spec/lib/trackerific/base_spec.rb +0 -34
@@ -4,7 +4,7 @@
|
|
4
4
|
<head>
|
5
5
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
6
6
|
<title>
|
7
|
-
Class: Trackerific::
|
7
|
+
Class: Trackerific::Service
|
8
8
|
|
9
9
|
— Documentation by YARD 0.7.1
|
10
10
|
|
@@ -33,10 +33,10 @@
|
|
33
33
|
<div id="header">
|
34
34
|
<div id="menu">
|
35
35
|
|
36
|
-
<a href="../_index.html">Index (
|
36
|
+
<a href="../_index.html">Index (S)</a> »
|
37
37
|
<span class='title'><span class='object_link'><a href="../Trackerific.html" title="Trackerific (module)">Trackerific</a></span></span>
|
38
38
|
»
|
39
|
-
<span class="title">
|
39
|
+
<span class="title">Service</span>
|
40
40
|
|
41
41
|
|
42
42
|
<div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
|
@@ -56,7 +56,7 @@
|
|
56
56
|
|
57
57
|
<iframe id="search_frame"></iframe>
|
58
58
|
|
59
|
-
<div id="content"><h1>Class: Trackerific::
|
59
|
+
<div id="content"><h1>Class: Trackerific::Service
|
60
60
|
|
61
61
|
|
62
62
|
|
@@ -71,7 +71,7 @@
|
|
71
71
|
<ul class="fullTree">
|
72
72
|
<li>Object</li>
|
73
73
|
|
74
|
-
<li class="next">Trackerific::
|
74
|
+
<li class="next">Trackerific::Service</li>
|
75
75
|
|
76
76
|
</ul>
|
77
77
|
<a href="#" class="inheritanceTree">show all</a>
|
@@ -83,11 +83,15 @@
|
|
83
83
|
|
84
84
|
|
85
85
|
|
86
|
+
<dt class="r2">Includes:</dt>
|
87
|
+
<dd class="r2"><span class='object_link'><a href="../OptionsHelper.html" title="OptionsHelper (module)">OptionsHelper</a></span></dd>
|
88
|
+
|
89
|
+
|
86
90
|
|
87
91
|
|
88
92
|
|
89
|
-
<dt class="
|
90
|
-
<dd class="
|
93
|
+
<dt class="r1 last">Defined in:</dt>
|
94
|
+
<dd class="r1 last">lib/trackerific/service.rb</dd>
|
91
95
|
|
92
96
|
</dl>
|
93
97
|
<div class="clear"></div>
|
@@ -95,7 +99,7 @@
|
|
95
99
|
<h2>Overview</h2><div class="docstring">
|
96
100
|
<div class="discussion">
|
97
101
|
<p>
|
98
|
-
Base class for Trackerific
|
102
|
+
Base class for Trackerific services
|
99
103
|
</p>
|
100
104
|
|
101
105
|
|
@@ -109,8 +113,15 @@ Base class for Trackerific package tracking services.
|
|
109
113
|
</div>
|
110
114
|
|
111
115
|
|
116
|
+
|
117
|
+
|
118
|
+
|
119
|
+
|
112
120
|
|
113
121
|
|
122
|
+
|
123
|
+
|
124
|
+
|
114
125
|
|
115
126
|
|
116
127
|
<h2>
|
@@ -181,7 +192,7 @@ class.
|
|
181
192
|
<li class="public ">
|
182
193
|
<span class="summary_signature">
|
183
194
|
|
184
|
-
<a href="#initialize-instance_method" title="#initialize (instance method)">- (
|
195
|
+
<a href="#initialize-instance_method" title="#initialize (instance method)">- (Service) <strong>initialize</strong>(options = {}) </a>
|
185
196
|
|
186
197
|
|
187
198
|
|
@@ -197,7 +208,7 @@ class.
|
|
197
208
|
|
198
209
|
|
199
210
|
<span class="summary_desc"><div class='inline'><p>
|
200
|
-
Creates a new instance of Trackerific::
|
211
|
+
Creates a new instance of Trackerific::Service with required options.
|
201
212
|
</p>
|
202
213
|
</div></span>
|
203
214
|
|
@@ -231,13 +242,23 @@ Gets the tracking information for the package from the server.
|
|
231
242
|
</ul>
|
232
243
|
|
233
244
|
|
245
|
+
|
246
|
+
|
247
|
+
|
248
|
+
|
249
|
+
|
250
|
+
|
251
|
+
|
252
|
+
|
253
|
+
<h3 class="inherited">Methods included from <span class='object_link'><a href="../OptionsHelper.html" title="OptionsHelper (module)">OptionsHelper</a></span></h3>
|
254
|
+
<p class="inherited"><span class='object_link'><a href="../OptionsHelper.html#validate_options-instance_method" title="OptionsHelper#validate_options (method)">#validate_options</a></span></p>
|
234
255
|
<div id="constructor_details" class="method_details_list">
|
235
256
|
<h2>Constructor Details</h2>
|
236
257
|
|
237
258
|
<div class="method_details first">
|
238
259
|
<p class="signature first" id="initialize-instance_method">
|
239
260
|
|
240
|
-
- (<tt><span class='object_link'><a href="" title="Trackerific::
|
261
|
+
- (<tt><span class='object_link'><a href="" title="Trackerific::Service (class)">Service</a></span></tt>) <strong>initialize</strong>(options = {})
|
241
262
|
|
242
263
|
|
243
264
|
|
@@ -248,7 +269,7 @@ Gets the tracking information for the package from the server.
|
|
248
269
|
You should avoid using this method if possible, as it may be removed or be changed in the future.
|
249
270
|
</p>
|
250
271
|
<p>
|
251
|
-
Creates a new instance of Trackerific::
|
272
|
+
Creates a new instance of Trackerific::Service with required options
|
252
273
|
</p>
|
253
274
|
|
254
275
|
|
@@ -262,32 +283,16 @@ Creates a new instance of Trackerific::Base with required options
|
|
262
283
|
<pre class="lines">
|
263
284
|
|
264
285
|
|
265
|
-
6
|
266
|
-
7
|
267
286
|
8
|
268
287
|
9
|
269
288
|
10
|
270
|
-
11
|
271
|
-
12
|
272
|
-
13
|
273
|
-
14
|
274
|
-
15
|
275
|
-
16
|
276
|
-
17</pre>
|
289
|
+
11</pre>
|
277
290
|
</td>
|
278
291
|
<td>
|
279
|
-
<pre class="code"><span class="info file"># File 'lib/trackerific/
|
292
|
+
<pre class="code"><span class="info file"># File 'lib/trackerific/service.rb', line 8</span>
|
280
293
|
|
281
294
|
<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span>
|
282
|
-
<span class='id
|
283
|
-
<span class='comment'># make sure all the required options exist
|
284
|
-
</span> <span class='id required'>required</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id k'>k</span><span class='op'>|</span>
|
285
|
-
<span class='id raise'>raise</span> <span class='const'>ArgumentError</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Missing required parameter: </span><span class='embexpr_beg'>#{</span><span class='id k'>k</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='id options'>options</span><span class='period'>.</span><span class='id has_key?'>has_key?</span><span class='lparen'>(</span><span class='id k'>k</span><span class='rparen'>)</span>
|
286
|
-
<span class='kw'>end</span>
|
287
|
-
<span class='comment'># make sure no invalid options exist
|
288
|
-
</span> <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id k'>k</span><span class='comma'>,</span> <span class='id v'>v</span><span class='op'>|</span>
|
289
|
-
<span class='id raise'>raise</span> <span class='const'>ArgumentError</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Invalid parameter: </span><span class='embexpr_beg'>#{</span><span class='id k'>k</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='id required'>required</span><span class='period'>.</span><span class='id include?'>include?</span><span class='lparen'>(</span><span class='id k'>k</span><span class='rparen'>)</span>
|
290
|
-
<span class='kw'>end</span>
|
295
|
+
<span class='id validate_options'>validate_options</span> <span class='id options'>options</span><span class='comma'>,</span> <span class='kw'>self</span><span class='period'>.</span><span class='id class'>class</span><span class='period'>.</span><span class='id required_options'>required_options</span>
|
291
296
|
<span class='ivar'>@options</span> <span class='op'>=</span> <span class='id options'>options</span>
|
292
297
|
<span class='kw'>end</span></pre>
|
293
298
|
</td>
|
@@ -328,7 +333,7 @@ Override this method in your custom tracking service
|
|
328
333
|
</p>
|
329
334
|
</div></h4>
|
330
335
|
<pre class="example code"><span class='kw'>module</span> <span class='const'>Trackerific</span>
|
331
|
-
<span class='kw'>class</span> <span class='const'>MyTrackingService</span> <span class='op'><</span> <span class='const'>
|
336
|
+
<span class='kw'>class</span> <span class='const'>MyTrackingService</span> <span class='op'><</span> <span class='const'>Service</span>
|
332
337
|
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id package_id_matchers'>package_id_matchers</span>
|
333
338
|
<span class='lbracket'>[</span> <span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^.Z</span><span class='regexp_end'>/</span></span><span class='comma'>,</span> <span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^[HK].{10}$</span><span class='regexp_end'>/</span></span> <span class='rbracket'>]</span> <span class='comment'># matchers for UPS package identifiers
|
334
339
|
</span> <span class='kw'>end</span>
|
@@ -362,14 +367,14 @@ an array of regular expressions
|
|
362
367
|
<pre class="lines">
|
363
368
|
|
364
369
|
|
365
|
-
|
366
|
-
|
367
|
-
|
370
|
+
46
|
371
|
+
47
|
372
|
+
48</pre>
|
368
373
|
</td>
|
369
374
|
<td>
|
370
|
-
<pre class="code"><span class="info file"># File 'lib/trackerific/
|
375
|
+
<pre class="code"><span class="info file"># File 'lib/trackerific/service.rb', line 46</span>
|
371
376
|
|
372
|
-
<span class='kw'>def</span> <span class='
|
377
|
+
<span class='kw'>def</span> <span class='id package_id_matchers'>package_id_matchers</span>
|
373
378
|
<span class='kw'>nil</span>
|
374
379
|
<span class='kw'>end</span></pre>
|
375
380
|
</td>
|
@@ -405,7 +410,7 @@ options
|
|
405
410
|
</p>
|
406
411
|
</div></h4>
|
407
412
|
<pre class="example code"><span class='kw'>module</span> <span class='const'>Trackerific</span>
|
408
|
-
<span class='kw'>class</span> <span class='const'>MyTrackingService</span> <span class='op'><</span> <span class='const'>
|
413
|
+
<span class='kw'>class</span> <span class='const'>MyTrackingService</span> <span class='op'><</span> <span class='const'>Service</span>
|
409
414
|
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id required_options'>required_options</span>
|
410
415
|
<span class='lbracket'>[</span><span class='symbol'>:all</span><span class='comma'>,</span> <span class='symbol'>:these</span><span class='comma'>,</span> <span class='symbol'>:are</span><span class='comma'>,</span> <span class='symbol'>:required</span><span class='rbracket'>]</span>
|
411
416
|
<span class='kw'>end</span>
|
@@ -439,14 +444,14 @@ the required options
|
|
439
444
|
<pre class="lines">
|
440
445
|
|
441
446
|
|
442
|
-
|
443
|
-
|
444
|
-
|
447
|
+
61
|
448
|
+
62
|
449
|
+
63</pre>
|
445
450
|
</td>
|
446
451
|
<td>
|
447
|
-
<pre class="code"><span class="info file"># File 'lib/trackerific/
|
452
|
+
<pre class="code"><span class="info file"># File 'lib/trackerific/service.rb', line 61</span>
|
448
453
|
|
449
|
-
<span class='kw'>def</span> <span class='
|
454
|
+
<span class='kw'>def</span> <span class='id required_options'>required_options</span>
|
450
455
|
<span class='lbracket'>[</span><span class='rbracket'>]</span>
|
451
456
|
<span class='kw'>end</span></pre>
|
452
457
|
</td>
|
@@ -486,7 +491,7 @@ Override this method in your custom tracking service to implement tracking
|
|
486
491
|
</p>
|
487
492
|
</div></h4>
|
488
493
|
<pre class="example code"><span class='kw'>module</span> <span class='const'>Trackerific</span>
|
489
|
-
<span class='kw'>class</span> <span class='const'>MyTrackingService</span> <span class='op'><</span> <span class='const'>
|
494
|
+
<span class='kw'>class</span> <span class='const'>MyTrackingService</span> <span class='op'><</span> <span class='const'>Trackerific</span><span class='op'>::</span><span class='const'>Service</span>
|
490
495
|
<span class='kw'>def</span> <span class='id track_package'>track_package</span>
|
491
496
|
<span class='comment'># your tracking code here
|
492
497
|
</span> <span class='const'>Trackerific</span><span class='op'>::</span><span class='const'>Details</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span>
|
@@ -545,12 +550,12 @@ the tracking details
|
|
545
550
|
<pre class="lines">
|
546
551
|
|
547
552
|
|
548
|
-
|
549
|
-
|
550
|
-
|
553
|
+
29
|
554
|
+
30
|
555
|
+
31</pre>
|
551
556
|
</td>
|
552
557
|
<td>
|
553
|
-
<pre class="code"><span class="info file"># File 'lib/trackerific/
|
558
|
+
<pre class="code"><span class="info file"># File 'lib/trackerific/service.rb', line 29</span>
|
554
559
|
|
555
560
|
<span class='kw'>def</span> <span class='id track_package'>track_package</span><span class='lparen'>(</span><span class='id package_id'>package_id</span><span class='rparen'>)</span>
|
556
561
|
<span class='ivar'>@package_id</span> <span class='op'>=</span> <span class='id package_id'>package_id</span>
|
@@ -565,7 +570,7 @@ the tracking details
|
|
565
570
|
</div>
|
566
571
|
|
567
572
|
<div id="footer">
|
568
|
-
Generated on
|
573
|
+
Generated on Wed Jun 15 15:30:27 2011 by
|
569
574
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
570
575
|
0.7.1 (ruby-1.9.2).
|
571
576
|
</div>
|
data/doc/Trackerific/UPS.html
CHANGED
@@ -66,12 +66,12 @@
|
|
66
66
|
|
67
67
|
<dt class="r1">Inherits:</dt>
|
68
68
|
<dd class="r1">
|
69
|
-
<span class="inheritName"><span class='object_link'><a href="
|
69
|
+
<span class="inheritName"><span class='object_link'><a href="Service.html" title="Trackerific::Service (class)">Service</a></span></span>
|
70
70
|
|
71
71
|
<ul class="fullTree">
|
72
72
|
<li>Object</li>
|
73
73
|
|
74
|
-
<li class="next"><span class='object_link'><a href="
|
74
|
+
<li class="next"><span class='object_link'><a href="Service.html" title="Trackerific::Service (class)">Service</a></span></li>
|
75
75
|
|
76
76
|
<li class="next">Trackerific::UPS</li>
|
77
77
|
|
@@ -116,12 +116,19 @@ Provides package tracking support for UPS.
|
|
116
116
|
|
117
117
|
|
118
118
|
|
119
|
+
|
120
|
+
|
121
|
+
|
122
|
+
|
119
123
|
|
120
124
|
|
121
125
|
|
122
126
|
|
123
127
|
|
124
128
|
|
129
|
+
|
130
|
+
|
131
|
+
|
125
132
|
|
126
133
|
|
127
134
|
<h2>
|
@@ -224,12 +231,22 @@ Tracks a UPS package.
|
|
224
231
|
|
225
232
|
|
226
233
|
|
227
|
-
<h3 class="inherited">Methods inherited from <span class='object_link'><a href="
|
228
|
-
<p class="inherited"><span class='object_link'><a href="
|
234
|
+
<h3 class="inherited">Methods inherited from <span class='object_link'><a href="Service.html" title="Trackerific::Service (class)">Service</a></span></h3>
|
235
|
+
<p class="inherited"><span class='object_link'><a href="Service.html#initialize-instance_method" title="Trackerific::Service#initialize (method)">#initialize</a></span></p>
|
236
|
+
|
237
|
+
|
238
|
+
|
239
|
+
|
240
|
+
|
241
|
+
|
242
|
+
|
243
|
+
|
244
|
+
<h3 class="inherited">Methods included from <span class='object_link'><a href="../OptionsHelper.html" title="OptionsHelper (module)">OptionsHelper</a></span></h3>
|
245
|
+
<p class="inherited"><span class='object_link'><a href="../OptionsHelper.html#validate_options-instance_method" title="OptionsHelper#validate_options (method)">#validate_options</a></span></p>
|
229
246
|
<div id="constructor_details" class="method_details_list">
|
230
247
|
<h2>Constructor Details</h2>
|
231
248
|
|
232
|
-
<p class="notice">This class inherits a constructor from <span class='object_link'><a href="
|
249
|
+
<p class="notice">This class inherits a constructor from <span class='object_link'><a href="Service.html#initialize-instance_method" title="Trackerific::Service#initialize (method)">Trackerific::Service</a></span></p>
|
233
250
|
|
234
251
|
</div>
|
235
252
|
|
@@ -285,14 +302,14 @@ the regular expression
|
|
285
302
|
<pre class="lines">
|
286
303
|
|
287
304
|
|
288
|
-
|
289
|
-
|
290
|
-
|
305
|
+
21
|
306
|
+
22
|
307
|
+
23</pre>
|
291
308
|
</td>
|
292
309
|
<td>
|
293
|
-
<pre class="code"><span class="info file"># File 'lib/trackerific/services/ups.rb', line
|
310
|
+
<pre class="code"><span class="info file"># File 'lib/trackerific/services/ups.rb', line 21</span>
|
294
311
|
|
295
|
-
<span class='kw'>def</span> <span class='
|
312
|
+
<span class='kw'>def</span> <span class='id package_id_matchers'>package_id_matchers</span>
|
296
313
|
<span class='lbracket'>[</span> <span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^.Z</span><span class='regexp_end'>/</span></span><span class='comma'>,</span> <span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^[HK].{10}$</span><span class='regexp_end'>/</span></span> <span class='rbracket'>]</span>
|
297
314
|
<span class='kw'>end</span></pre>
|
298
315
|
</td>
|
@@ -347,14 +364,14 @@ the required options for tracking a UPS package
|
|
347
364
|
<pre class="lines">
|
348
365
|
|
349
366
|
|
350
|
-
|
351
|
-
|
352
|
-
|
367
|
+
27
|
368
|
+
28
|
369
|
+
29</pre>
|
353
370
|
</td>
|
354
371
|
<td>
|
355
|
-
<pre class="code"><span class="info file"># File 'lib/trackerific/services/ups.rb', line
|
372
|
+
<pre class="code"><span class="info file"># File 'lib/trackerific/services/ups.rb', line 27</span>
|
356
373
|
|
357
|
-
<span class='kw'>def</span> <span class='
|
374
|
+
<span class='kw'>def</span> <span class='id required_options'>required_options</span>
|
358
375
|
<span class='lbracket'>[</span><span class='symbol'>:key</span><span class='comma'>,</span> <span class='symbol'>:user_id</span><span class='comma'>,</span> <span class='symbol'>:password</span><span class='rbracket'>]</span>
|
359
376
|
<span class='kw'>end</span></pre>
|
360
377
|
</td>
|
@@ -464,23 +481,23 @@ package, etc.)
|
|
464
481
|
<pre class="lines">
|
465
482
|
|
466
483
|
|
467
|
-
|
468
|
-
|
469
|
-
|
470
|
-
|
471
|
-
|
472
|
-
|
473
|
-
|
474
|
-
|
475
|
-
|
476
|
-
|
477
|
-
|
478
|
-
|
479
|
-
|
480
|
-
|
484
|
+
40
|
485
|
+
41
|
486
|
+
42
|
487
|
+
43
|
488
|
+
44
|
489
|
+
45
|
490
|
+
46
|
491
|
+
47
|
492
|
+
48
|
493
|
+
49
|
494
|
+
50
|
495
|
+
51
|
496
|
+
52
|
497
|
+
53</pre>
|
481
498
|
</td>
|
482
499
|
<td>
|
483
|
-
<pre class="code"><span class="info file"># File 'lib/trackerific/services/ups.rb', line
|
500
|
+
<pre class="code"><span class="info file"># File 'lib/trackerific/services/ups.rb', line 40</span>
|
484
501
|
|
485
502
|
<span class='kw'>def</span> <span class='id track_package'>track_package</span><span class='lparen'>(</span><span class='id package_id'>package_id</span><span class='rparen'>)</span>
|
486
503
|
<span class='kw'>super</span>
|
@@ -506,7 +523,7 @@ package, etc.)
|
|
506
523
|
</div>
|
507
524
|
|
508
525
|
<div id="footer">
|
509
|
-
Generated on
|
526
|
+
Generated on Wed Jun 15 15:30:27 2011 by
|
510
527
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
511
528
|
0.7.1 (ruby-1.9.2).
|
512
529
|
</div>
|
data/doc/Trackerific/USPS.html
CHANGED
@@ -66,12 +66,12 @@
|
|
66
66
|
|
67
67
|
<dt class="r1">Inherits:</dt>
|
68
68
|
<dd class="r1">
|
69
|
-
<span class="inheritName"><span class='object_link'><a href="
|
69
|
+
<span class="inheritName"><span class='object_link'><a href="Service.html" title="Trackerific::Service (class)">Service</a></span></span>
|
70
70
|
|
71
71
|
<ul class="fullTree">
|
72
72
|
<li>Object</li>
|
73
73
|
|
74
|
-
<li class="next"><span class='object_link'><a href="
|
74
|
+
<li class="next"><span class='object_link'><a href="Service.html" title="Trackerific::Service (class)">Service</a></span></li>
|
75
75
|
|
76
76
|
<li class="next">Trackerific::USPS</li>
|
77
77
|
|
@@ -116,12 +116,19 @@ Provides package tracking support for USPS.
|
|
116
116
|
|
117
117
|
|
118
118
|
|
119
|
+
|
120
|
+
|
121
|
+
|
122
|
+
|
119
123
|
|
120
124
|
|
121
125
|
|
122
126
|
|
123
127
|
|
124
128
|
|
129
|
+
|
130
|
+
|
131
|
+
|
125
132
|
|
126
133
|
|
127
134
|
<h2>
|
@@ -224,12 +231,22 @@ Tracks a USPS package.
|
|
224
231
|
|
225
232
|
|
226
233
|
|
227
|
-
<h3 class="inherited">Methods inherited from <span class='object_link'><a href="
|
228
|
-
<p class="inherited"><span class='object_link'><a href="
|
234
|
+
<h3 class="inherited">Methods inherited from <span class='object_link'><a href="Service.html" title="Trackerific::Service (class)">Service</a></span></h3>
|
235
|
+
<p class="inherited"><span class='object_link'><a href="Service.html#initialize-instance_method" title="Trackerific::Service#initialize (method)">#initialize</a></span></p>
|
236
|
+
|
237
|
+
|
238
|
+
|
239
|
+
|
240
|
+
|
241
|
+
|
242
|
+
|
243
|
+
|
244
|
+
<h3 class="inherited">Methods included from <span class='object_link'><a href="../OptionsHelper.html" title="OptionsHelper (module)">OptionsHelper</a></span></h3>
|
245
|
+
<p class="inherited"><span class='object_link'><a href="../OptionsHelper.html#validate_options-instance_method" title="OptionsHelper#validate_options (method)">#validate_options</a></span></p>
|
229
246
|
<div id="constructor_details" class="method_details_list">
|
230
247
|
<h2>Constructor Details</h2>
|
231
248
|
|
232
|
-
<p class="notice">This class inherits a constructor from <span class='object_link'><a href="
|
249
|
+
<p class="notice">This class inherits a constructor from <span class='object_link'><a href="Service.html#initialize-instance_method" title="Trackerific::Service#initialize (method)">Trackerific::Service</a></span></p>
|
233
250
|
|
234
251
|
</div>
|
235
252
|
|
@@ -285,14 +302,14 @@ the regular expression
|
|
285
302
|
<pre class="lines">
|
286
303
|
|
287
304
|
|
288
|
-
|
289
|
-
|
290
|
-
|
305
|
+
22
|
306
|
+
23
|
307
|
+
24</pre>
|
291
308
|
</td>
|
292
309
|
<td>
|
293
|
-
<pre class="code"><span class="info file"># File 'lib/trackerific/services/usps.rb', line
|
310
|
+
<pre class="code"><span class="info file"># File 'lib/trackerific/services/usps.rb', line 22</span>
|
294
311
|
|
295
|
-
<span class='kw'>def</span> <span class='
|
312
|
+
<span class='kw'>def</span> <span class='id package_id_matchers'>package_id_matchers</span>
|
296
313
|
<span class='lbracket'>[</span> <span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^E\D{1}\d{9}\D{2}$|^9\d{15,21}$</span><span class='regexp_end'>/</span></span> <span class='rbracket'>]</span>
|
297
314
|
<span class='kw'>end</span></pre>
|
298
315
|
</td>
|
@@ -347,14 +364,14 @@ the required options for tracking a UPS package
|
|
347
364
|
<pre class="lines">
|
348
365
|
|
349
366
|
|
350
|
-
|
351
|
-
|
352
|
-
|
367
|
+
29
|
368
|
+
30
|
369
|
+
31</pre>
|
353
370
|
</td>
|
354
371
|
<td>
|
355
|
-
<pre class="code"><span class="info file"># File 'lib/trackerific/services/usps.rb', line
|
372
|
+
<pre class="code"><span class="info file"># File 'lib/trackerific/services/usps.rb', line 29</span>
|
356
373
|
|
357
|
-
<span class='kw'>def</span> <span class='
|
374
|
+
<span class='kw'>def</span> <span class='id required_options'>required_options</span>
|
358
375
|
<span class='lbracket'>[</span><span class='symbol'>:user_id</span><span class='rbracket'>]</span>
|
359
376
|
<span class='kw'>end</span></pre>
|
360
377
|
</td>
|
@@ -464,22 +481,6 @@ package, etc.)
|
|
464
481
|
<pre class="lines">
|
465
482
|
|
466
483
|
|
467
|
-
26
|
468
|
-
27
|
469
|
-
28
|
470
|
-
29
|
471
|
-
30
|
472
|
-
31
|
473
|
-
32
|
474
|
-
33
|
475
|
-
34
|
476
|
-
35
|
477
|
-
36
|
478
|
-
37
|
479
|
-
38
|
480
|
-
39
|
481
|
-
40
|
482
|
-
41
|
483
484
|
42
|
484
485
|
43
|
485
486
|
44
|
@@ -495,10 +496,26 @@ package, etc.)
|
|
495
496
|
54
|
496
497
|
55
|
497
498
|
56
|
498
|
-
57
|
499
|
+
57
|
500
|
+
58
|
501
|
+
59
|
502
|
+
60
|
503
|
+
61
|
504
|
+
62
|
505
|
+
63
|
506
|
+
64
|
507
|
+
65
|
508
|
+
66
|
509
|
+
67
|
510
|
+
68
|
511
|
+
69
|
512
|
+
70
|
513
|
+
71
|
514
|
+
72
|
515
|
+
73</pre>
|
499
516
|
</td>
|
500
517
|
<td>
|
501
|
-
<pre class="code"><span class="info file"># File 'lib/trackerific/services/usps.rb', line
|
518
|
+
<pre class="code"><span class="info file"># File 'lib/trackerific/services/usps.rb', line 42</span>
|
502
519
|
|
503
520
|
<span class='kw'>def</span> <span class='id track_package'>track_package</span><span class='lparen'>(</span><span class='id package_id'>package_id</span><span class='rparen'>)</span>
|
504
521
|
<span class='kw'>super</span>
|
@@ -542,7 +559,7 @@ package, etc.)
|
|
542
559
|
</div>
|
543
560
|
|
544
561
|
<div id="footer">
|
545
|
-
Generated on
|
562
|
+
Generated on Wed Jun 15 15:30:27 2011 by
|
546
563
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
547
564
|
0.7.1 (ruby-1.9.2).
|
548
565
|
</div>
|