songkickr 0.1.4 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- data/LICENSE +1 -1
- data/README.rdoc +11 -4
- data/VERSION +1 -1
- data/doc/APIKeyNotSet.html +214 -0
- data/doc/LICENSE.html +133 -0
- data/doc/README_rdoc.html +170 -0
- data/doc/Songkickr/Artist.html +305 -0
- data/doc/Songkickr/ArtistResult.html +334 -0
- data/doc/Songkickr/ConcertSetlistResult.html +301 -0
- data/doc/Songkickr/Event.html +556 -0
- data/doc/Songkickr/EventResult.html +332 -0
- data/doc/Songkickr/Location.html +326 -0
- data/doc/Songkickr/LocationResult.html +335 -0
- data/doc/Songkickr/Performance.html +326 -0
- data/doc/Songkickr/Remote.html +715 -0
- data/doc/Songkickr/Setlist.html +398 -0
- data/doc/Songkickr/SetlistItem.html +263 -0
- data/doc/Songkickr/Venue.html +292 -0
- data/doc/Songkickr.html +328 -0
- data/doc/created.rid +16 -0
- data/doc/images/brick.png +0 -0
- data/doc/images/brick_link.png +0 -0
- data/doc/images/bug.png +0 -0
- data/doc/images/bullet_black.png +0 -0
- data/doc/images/bullet_toggle_minus.png +0 -0
- data/doc/images/bullet_toggle_plus.png +0 -0
- data/doc/images/date.png +0 -0
- data/doc/images/find.png +0 -0
- data/doc/images/loadingAnimation.gif +0 -0
- data/doc/images/macFFBgHack.png +0 -0
- data/doc/images/package.png +0 -0
- data/doc/images/page_green.png +0 -0
- data/doc/images/page_white_text.png +0 -0
- data/doc/images/page_white_width.png +0 -0
- data/doc/images/plugin.png +0 -0
- data/doc/images/ruby.png +0 -0
- data/doc/images/tag_green.png +0 -0
- data/doc/images/wrench.png +0 -0
- data/doc/images/wrench_orange.png +0 -0
- data/doc/images/zoom.png +0 -0
- data/doc/index.html +144 -0
- data/doc/js/darkfish.js +116 -0
- data/doc/js/jquery.js +32 -0
- data/doc/js/quicksearch.js +114 -0
- data/doc/js/thickbox-compressed.js +10 -0
- data/doc/lib/songkickr/artist_rb.html +52 -0
- data/doc/lib/songkickr/artist_result_rb.html +52 -0
- data/doc/lib/songkickr/concert_setlist_result_rb.html +52 -0
- data/doc/lib/songkickr/event_rb.html +52 -0
- data/doc/lib/songkickr/event_result_rb.html +52 -0
- data/doc/lib/songkickr/location_rb.html +52 -0
- data/doc/lib/songkickr/location_result_rb.html +52 -0
- data/doc/lib/songkickr/performance_rb.html +52 -0
- data/doc/lib/songkickr/remote_rb.html +52 -0
- data/doc/lib/songkickr/setlist_item_rb.html +52 -0
- data/doc/lib/songkickr/setlist_rb.html +52 -0
- data/doc/lib/songkickr/venue_rb.html +52 -0
- data/doc/lib/songkickr_rb.html +56 -0
- data/doc/rdoc.css +759 -0
- data/lib/songkickr/artist.rb +17 -6
- data/lib/songkickr/artist_result.rb +25 -22
- data/lib/songkickr/concert_setlist_result.rb +6 -2
- data/lib/songkickr/event.rb +42 -3
- data/lib/songkickr/event_result.rb +3 -1
- data/lib/songkickr/location.rb +28 -3
- data/lib/songkickr/location_result.rb +8 -3
- data/lib/songkickr/performance.rb +20 -4
- data/lib/songkickr/remote.rb +102 -60
- data/lib/songkickr/setlist.rb +20 -0
- data/lib/songkickr/setlist_item.rb +6 -0
- data/lib/songkickr.rb +16 -3
- data/songkickr.gemspec +60 -12
- data/test.rb +12 -11
- metadata +66 -13
@@ -0,0 +1,556 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
3
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
4
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
5
|
+
<head>
|
6
|
+
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type" />
|
7
|
+
|
8
|
+
<title>Class: Songkickr::Event</title>
|
9
|
+
|
10
|
+
<link rel="stylesheet" href="../rdoc.css" type="text/css" media="screen" />
|
11
|
+
|
12
|
+
<script src="../js/jquery.js" type="text/javascript" charset="utf-8"></script>
|
13
|
+
<script src="../js/thickbox-compressed.js" type="text/javascript" charset="utf-8"></script>
|
14
|
+
<script src="../js/quicksearch.js" type="text/javascript" charset="utf-8"></script>
|
15
|
+
<script src="../js/darkfish.js" type="text/javascript" charset="utf-8"></script>
|
16
|
+
|
17
|
+
</head>
|
18
|
+
<body id="top" class="class">
|
19
|
+
|
20
|
+
<div id="metadata">
|
21
|
+
<div id="home-metadata">
|
22
|
+
<div id="home-section" class="section">
|
23
|
+
<h3 class="section-header">
|
24
|
+
<a href="../index.html">Home</a>
|
25
|
+
<a href="../index.html#classes">Classes</a>
|
26
|
+
<a href="../index.html#methods">Methods</a>
|
27
|
+
</h3>
|
28
|
+
</div>
|
29
|
+
</div>
|
30
|
+
|
31
|
+
<div id="file-metadata">
|
32
|
+
<div id="file-list-section" class="section">
|
33
|
+
<h3 class="section-header">In Files</h3>
|
34
|
+
<div class="section-body">
|
35
|
+
<ul>
|
36
|
+
|
37
|
+
<li><a href="../lib/songkickr/event_rb.html?TB_iframe=true&height=550&width=785"
|
38
|
+
class="thickbox" title="lib/songkickr/event.rb">lib/songkickr/event.rb</a></li>
|
39
|
+
|
40
|
+
</ul>
|
41
|
+
</div>
|
42
|
+
</div>
|
43
|
+
|
44
|
+
|
45
|
+
</div>
|
46
|
+
|
47
|
+
<div id="class-metadata">
|
48
|
+
|
49
|
+
<!-- Parent Class -->
|
50
|
+
<div id="parent-class-section" class="section">
|
51
|
+
<h3 class="section-header">Parent</h3>
|
52
|
+
|
53
|
+
<p class="link">Object</p>
|
54
|
+
|
55
|
+
</div>
|
56
|
+
|
57
|
+
|
58
|
+
|
59
|
+
|
60
|
+
|
61
|
+
|
62
|
+
|
63
|
+
<!-- Method Quickref -->
|
64
|
+
<div id="method-list-section" class="section">
|
65
|
+
<h3 class="section-header">Methods</h3>
|
66
|
+
<ul class="link-list">
|
67
|
+
|
68
|
+
<li><a href="#method-c-new">::new</a></li>
|
69
|
+
|
70
|
+
<li><a href="#method-i-parse_performance">#parse_performance</a></li>
|
71
|
+
|
72
|
+
<li><a href="#method-i-start_hash_to_datetime">#start_hash_to_datetime</a></li>
|
73
|
+
|
74
|
+
</ul>
|
75
|
+
</div>
|
76
|
+
|
77
|
+
|
78
|
+
|
79
|
+
</div>
|
80
|
+
|
81
|
+
<div id="project-metadata">
|
82
|
+
|
83
|
+
|
84
|
+
<div id="fileindex-section" class="section project-section">
|
85
|
+
<h3 class="section-header">Files</h3>
|
86
|
+
<ul>
|
87
|
+
|
88
|
+
<li class="file"><a href="../LICENSE.html">LICENSE</a></li>
|
89
|
+
|
90
|
+
<li class="file"><a href="../README_rdoc.html">README.rdoc</a></li>
|
91
|
+
|
92
|
+
</ul>
|
93
|
+
</div>
|
94
|
+
|
95
|
+
|
96
|
+
<div id="classindex-section" class="section project-section">
|
97
|
+
<h3 class="section-header">Class/Module Index
|
98
|
+
<span class="search-toggle"><img src="../images/find.png"
|
99
|
+
height="16" width="16" alt="[+]"
|
100
|
+
title="show/hide quicksearch" /></span></h3>
|
101
|
+
<form action="#" method="get" accept-charset="utf-8" class="initially-hidden">
|
102
|
+
<fieldset>
|
103
|
+
<legend>Quicksearch</legend>
|
104
|
+
<input type="text" name="quicksearch" value=""
|
105
|
+
class="quicksearch-field" />
|
106
|
+
</fieldset>
|
107
|
+
</form>
|
108
|
+
|
109
|
+
<ul class="link-list">
|
110
|
+
|
111
|
+
<li><a href="../Songkickr.html">Songkickr</a></li>
|
112
|
+
|
113
|
+
<li><a href="../Songkickr/Artist.html">Songkickr::Artist</a></li>
|
114
|
+
|
115
|
+
<li><a href="../Songkickr/ArtistResult.html">Songkickr::ArtistResult</a></li>
|
116
|
+
|
117
|
+
<li><a href="../Songkickr/ConcertSetlistResult.html">Songkickr::ConcertSetlistResult</a></li>
|
118
|
+
|
119
|
+
<li><a href="../Songkickr/Event.html">Songkickr::Event</a></li>
|
120
|
+
|
121
|
+
<li><a href="../Songkickr/EventResult.html">Songkickr::EventResult</a></li>
|
122
|
+
|
123
|
+
<li><a href="../Songkickr/Location.html">Songkickr::Location</a></li>
|
124
|
+
|
125
|
+
<li><a href="../Songkickr/LocationResult.html">Songkickr::LocationResult</a></li>
|
126
|
+
|
127
|
+
<li><a href="../Songkickr/Performance.html">Songkickr::Performance</a></li>
|
128
|
+
|
129
|
+
<li><a href="../Songkickr/Remote.html">Songkickr::Remote</a></li>
|
130
|
+
|
131
|
+
<li><a href="../Songkickr/Setlist.html">Songkickr::Setlist</a></li>
|
132
|
+
|
133
|
+
<li><a href="../Songkickr/SetlistItem.html">Songkickr::SetlistItem</a></li>
|
134
|
+
|
135
|
+
<li><a href="../Songkickr/Venue.html">Songkickr::Venue</a></li>
|
136
|
+
|
137
|
+
<li><a href="../APIKeyNotSet.html">APIKeyNotSet</a></li>
|
138
|
+
|
139
|
+
</ul>
|
140
|
+
<div id="no-class-search-results" style="display: none;">No matching classes.</div>
|
141
|
+
</div>
|
142
|
+
|
143
|
+
|
144
|
+
</div>
|
145
|
+
</div>
|
146
|
+
|
147
|
+
<div id="documentation">
|
148
|
+
<h1 class="class">Songkickr::Event</h1>
|
149
|
+
|
150
|
+
<div id="description" class="description">
|
151
|
+
|
152
|
+
<p>A single event</p>
|
153
|
+
|
154
|
+
<pre>{
|
155
|
+
"displayName": "Vampire Weekend at O2 Academy Brixton (February 16, 2010)",
|
156
|
+
"type": "Concert",
|
157
|
+
"uri": "http://www.songkick.com/concerts/3037536-vampire-weekend-at-o2-academy-brixton?utm_medium=partner&utm_source=131",
|
158
|
+
"venue": {
|
159
|
+
"lng": -0.1187418,
|
160
|
+
"displayName": "O2 Academy Brixton",
|
161
|
+
"lat": 51.4681089,
|
162
|
+
"id": 17522
|
163
|
+
},
|
164
|
+
"location": {
|
165
|
+
"lng": -0.1187418,
|
166
|
+
"city": "London, UK",
|
167
|
+
"lat": 51.4681089
|
168
|
+
},
|
169
|
+
"start": {
|
170
|
+
"time": "19:30:00",
|
171
|
+
"date": "2010-02-16"
|
172
|
+
},
|
173
|
+
"performance": [{
|
174
|
+
"artist": {
|
175
|
+
"uri": "http://www.songkick.com/artists/288696-vampire-weekend",
|
176
|
+
"displayName": "Vampire Weekend",
|
177
|
+
"id": 288696,
|
178
|
+
"identifier": [{"mbid": "af37c51c-0790-4a29-b995-456f98a6b8c9"}]
|
179
|
+
}
|
180
|
+
"displayName": "Vampire Weekend",
|
181
|
+
"billingIndex": 1,
|
182
|
+
"id": 5380281,
|
183
|
+
"billing": "headline"
|
184
|
+
}],
|
185
|
+
"id": 3037536
|
186
|
+
}</pre>
|
187
|
+
|
188
|
+
<p><a
|
189
|
+
href="http://www.songkick.com/developer/artist-search">www.songkick.com/developer/artist-search</a></p>
|
190
|
+
|
191
|
+
</div><!-- description -->
|
192
|
+
|
193
|
+
|
194
|
+
<div id="5Buntitled-5D" class="documentation-section">
|
195
|
+
|
196
|
+
|
197
|
+
|
198
|
+
|
199
|
+
|
200
|
+
|
201
|
+
|
202
|
+
<!-- Attributes -->
|
203
|
+
<div id="attribute-method-details" class="method-section section">
|
204
|
+
<h3 class="section-header">Attributes</h3>
|
205
|
+
|
206
|
+
|
207
|
+
<div id="display_name-attribute-method" class="method-detail">
|
208
|
+
<a name="display_name"></a>
|
209
|
+
|
210
|
+
<a name="display_name="></a>
|
211
|
+
|
212
|
+
<div class="method-heading attribute-method-heading">
|
213
|
+
<span class="method-name">display_name</span><span
|
214
|
+
class="attribute-access-type">[RW]</span>
|
215
|
+
</div>
|
216
|
+
|
217
|
+
<div class="method-description">
|
218
|
+
|
219
|
+
|
220
|
+
|
221
|
+
</div>
|
222
|
+
</div>
|
223
|
+
|
224
|
+
<div id="id-attribute-method" class="method-detail">
|
225
|
+
<a name="id"></a>
|
226
|
+
|
227
|
+
<a name="id="></a>
|
228
|
+
|
229
|
+
<div class="method-heading attribute-method-heading">
|
230
|
+
<span class="method-name">id</span><span
|
231
|
+
class="attribute-access-type">[RW]</span>
|
232
|
+
</div>
|
233
|
+
|
234
|
+
<div class="method-description">
|
235
|
+
|
236
|
+
|
237
|
+
|
238
|
+
</div>
|
239
|
+
</div>
|
240
|
+
|
241
|
+
<div id="lat-attribute-method" class="method-detail">
|
242
|
+
<a name="lat"></a>
|
243
|
+
|
244
|
+
<a name="lat="></a>
|
245
|
+
|
246
|
+
<div class="method-heading attribute-method-heading">
|
247
|
+
<span class="method-name">lat</span><span
|
248
|
+
class="attribute-access-type">[RW]</span>
|
249
|
+
</div>
|
250
|
+
|
251
|
+
<div class="method-description">
|
252
|
+
|
253
|
+
|
254
|
+
|
255
|
+
</div>
|
256
|
+
</div>
|
257
|
+
|
258
|
+
<div id="lng-attribute-method" class="method-detail">
|
259
|
+
<a name="lng"></a>
|
260
|
+
|
261
|
+
<a name="lng="></a>
|
262
|
+
|
263
|
+
<div class="method-heading attribute-method-heading">
|
264
|
+
<span class="method-name">lng</span><span
|
265
|
+
class="attribute-access-type">[RW]</span>
|
266
|
+
</div>
|
267
|
+
|
268
|
+
<div class="method-description">
|
269
|
+
|
270
|
+
|
271
|
+
|
272
|
+
</div>
|
273
|
+
</div>
|
274
|
+
|
275
|
+
<div id="location-attribute-method" class="method-detail">
|
276
|
+
<a name="location"></a>
|
277
|
+
|
278
|
+
<a name="location="></a>
|
279
|
+
|
280
|
+
<div class="method-heading attribute-method-heading">
|
281
|
+
<span class="method-name">location</span><span
|
282
|
+
class="attribute-access-type">[RW]</span>
|
283
|
+
</div>
|
284
|
+
|
285
|
+
<div class="method-description">
|
286
|
+
|
287
|
+
|
288
|
+
|
289
|
+
</div>
|
290
|
+
</div>
|
291
|
+
|
292
|
+
<div id="performances-attribute-method" class="method-detail">
|
293
|
+
<a name="performances"></a>
|
294
|
+
|
295
|
+
<a name="performances="></a>
|
296
|
+
|
297
|
+
<div class="method-heading attribute-method-heading">
|
298
|
+
<span class="method-name">performances</span><span
|
299
|
+
class="attribute-access-type">[RW]</span>
|
300
|
+
</div>
|
301
|
+
|
302
|
+
<div class="method-description">
|
303
|
+
|
304
|
+
|
305
|
+
|
306
|
+
</div>
|
307
|
+
</div>
|
308
|
+
|
309
|
+
<div id="start-attribute-method" class="method-detail">
|
310
|
+
<a name="start"></a>
|
311
|
+
|
312
|
+
<a name="start="></a>
|
313
|
+
|
314
|
+
<div class="method-heading attribute-method-heading">
|
315
|
+
<span class="method-name">start</span><span
|
316
|
+
class="attribute-access-type">[RW]</span>
|
317
|
+
</div>
|
318
|
+
|
319
|
+
<div class="method-description">
|
320
|
+
|
321
|
+
|
322
|
+
|
323
|
+
</div>
|
324
|
+
</div>
|
325
|
+
|
326
|
+
<div id="status-attribute-method" class="method-detail">
|
327
|
+
<a name="status"></a>
|
328
|
+
|
329
|
+
<a name="status="></a>
|
330
|
+
|
331
|
+
<div class="method-heading attribute-method-heading">
|
332
|
+
<span class="method-name">status</span><span
|
333
|
+
class="attribute-access-type">[RW]</span>
|
334
|
+
</div>
|
335
|
+
|
336
|
+
<div class="method-description">
|
337
|
+
|
338
|
+
|
339
|
+
|
340
|
+
</div>
|
341
|
+
</div>
|
342
|
+
|
343
|
+
<div id="tickets_uri-attribute-method" class="method-detail">
|
344
|
+
<a name="tickets_uri"></a>
|
345
|
+
|
346
|
+
<a name="tickets_uri="></a>
|
347
|
+
|
348
|
+
<div class="method-heading attribute-method-heading">
|
349
|
+
<span class="method-name">tickets_uri</span><span
|
350
|
+
class="attribute-access-type">[RW]</span>
|
351
|
+
</div>
|
352
|
+
|
353
|
+
<div class="method-description">
|
354
|
+
|
355
|
+
|
356
|
+
|
357
|
+
</div>
|
358
|
+
</div>
|
359
|
+
|
360
|
+
<div id="type-attribute-method" class="method-detail">
|
361
|
+
<a name="type"></a>
|
362
|
+
|
363
|
+
<a name="type="></a>
|
364
|
+
|
365
|
+
<div class="method-heading attribute-method-heading">
|
366
|
+
<span class="method-name">type</span><span
|
367
|
+
class="attribute-access-type">[RW]</span>
|
368
|
+
</div>
|
369
|
+
|
370
|
+
<div class="method-description">
|
371
|
+
|
372
|
+
|
373
|
+
|
374
|
+
</div>
|
375
|
+
</div>
|
376
|
+
|
377
|
+
<div id="uri-attribute-method" class="method-detail">
|
378
|
+
<a name="uri"></a>
|
379
|
+
|
380
|
+
<a name="uri="></a>
|
381
|
+
|
382
|
+
<div class="method-heading attribute-method-heading">
|
383
|
+
<span class="method-name">uri</span><span
|
384
|
+
class="attribute-access-type">[RW]</span>
|
385
|
+
</div>
|
386
|
+
|
387
|
+
<div class="method-description">
|
388
|
+
|
389
|
+
|
390
|
+
|
391
|
+
</div>
|
392
|
+
</div>
|
393
|
+
|
394
|
+
<div id="venue-attribute-method" class="method-detail">
|
395
|
+
<a name="venue"></a>
|
396
|
+
|
397
|
+
<a name="venue="></a>
|
398
|
+
|
399
|
+
<div class="method-heading attribute-method-heading">
|
400
|
+
<span class="method-name">venue</span><span
|
401
|
+
class="attribute-access-type">[RW]</span>
|
402
|
+
</div>
|
403
|
+
|
404
|
+
<div class="method-description">
|
405
|
+
|
406
|
+
|
407
|
+
|
408
|
+
</div>
|
409
|
+
</div>
|
410
|
+
|
411
|
+
</div><!-- attribute-method-details -->
|
412
|
+
|
413
|
+
|
414
|
+
<!-- Methods -->
|
415
|
+
|
416
|
+
<div id="protected-instance-method-details" class="method-section section">
|
417
|
+
<h3 class="section-header">Protected Instance Methods</h3>
|
418
|
+
|
419
|
+
|
420
|
+
<div id="parse_performance-method" class="method-detail ">
|
421
|
+
<a name="method-i-parse_performance"></a>
|
422
|
+
|
423
|
+
|
424
|
+
<div class="method-heading">
|
425
|
+
<span class="method-name">parse_performance</span><span
|
426
|
+
class="method-args">(performance_array = nil)</span>
|
427
|
+
<span class="method-click-advice">click to toggle source</span>
|
428
|
+
</div>
|
429
|
+
|
430
|
+
|
431
|
+
<div class="method-description">
|
432
|
+
|
433
|
+
<p>Builds a list of <a href="Performance.html">Performance</a> objects.</p>
|
434
|
+
|
435
|
+
|
436
|
+
|
437
|
+
<div class="method-source-code" id="parse_performance-source">
|
438
|
+
<pre>
|
439
|
+
<span class="ruby-comment"># File lib/songkickr/event.rb, line 63</span>
|
440
|
+
<span class="ruby-keyword">def</span> <span class="ruby-identifier">parse_performance</span>(<span class="ruby-identifier">performance_array</span> = <span class="ruby-keyword">nil</span>)
|
441
|
+
<span class="ruby-identifier">performances</span> = []
|
442
|
+
<span class="ruby-keyword">if</span> <span class="ruby-identifier">performance_array</span>
|
443
|
+
<span class="ruby-identifier">performance_array</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">performance</span><span class="ruby-operator">|</span>
|
444
|
+
<span class="ruby-identifier">performances</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">Songkickr</span><span class="ruby-operator">::</span><span class="ruby-constant">Performance</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">performance</span>)
|
445
|
+
<span class="ruby-keyword">end</span>
|
446
|
+
<span class="ruby-keyword">end</span>
|
447
|
+
|
448
|
+
<span class="ruby-identifier">performances</span>
|
449
|
+
<span class="ruby-keyword">end</span></pre>
|
450
|
+
</div><!-- parse_performance-source -->
|
451
|
+
|
452
|
+
</div>
|
453
|
+
|
454
|
+
|
455
|
+
|
456
|
+
|
457
|
+
</div><!-- parse_performance-method -->
|
458
|
+
|
459
|
+
|
460
|
+
<div id="start_hash_to_datetime-method" class="method-detail ">
|
461
|
+
<a name="method-i-start_hash_to_datetime"></a>
|
462
|
+
|
463
|
+
|
464
|
+
<div class="method-heading">
|
465
|
+
<span class="method-name">start_hash_to_datetime</span><span
|
466
|
+
class="method-args">(start_hash)</span>
|
467
|
+
<span class="method-click-advice">click to toggle source</span>
|
468
|
+
</div>
|
469
|
+
|
470
|
+
|
471
|
+
<div class="method-description">
|
472
|
+
|
473
|
+
<p>Takes the start hash and turns in into a DateTime object.</p>
|
474
|
+
|
475
|
+
|
476
|
+
|
477
|
+
<div class="method-source-code" id="start_hash_to_datetime-source">
|
478
|
+
<pre>
|
479
|
+
<span class="ruby-comment"># File lib/songkickr/event.rb, line 58</span>
|
480
|
+
<span class="ruby-keyword">def</span> <span class="ruby-identifier">start_hash_to_datetime</span>(<span class="ruby-identifier">start_hash</span>)
|
481
|
+
<span class="ruby-identifier">datetime</span> = <span class="ruby-constant">DateTime</span>.<span class="ruby-identifier">parse</span>(<span class="ruby-node">"#{start_hash["date"]} #{start_hash["time"]}"</span>)
|
482
|
+
<span class="ruby-keyword">end</span></pre>
|
483
|
+
</div><!-- start_hash_to_datetime-source -->
|
484
|
+
|
485
|
+
</div>
|
486
|
+
|
487
|
+
|
488
|
+
|
489
|
+
|
490
|
+
</div><!-- start_hash_to_datetime-method -->
|
491
|
+
|
492
|
+
|
493
|
+
</div><!-- protected-instance-method-details -->
|
494
|
+
|
495
|
+
<div id="public-class-method-details" class="method-section section">
|
496
|
+
<h3 class="section-header">Public Class Methods</h3>
|
497
|
+
|
498
|
+
|
499
|
+
<div id="new-method" class="method-detail ">
|
500
|
+
<a name="method-c-new"></a>
|
501
|
+
|
502
|
+
|
503
|
+
<div class="method-heading">
|
504
|
+
<span class="method-name">new</span><span
|
505
|
+
class="method-args">(event_hash)</span>
|
506
|
+
<span class="method-click-advice">click to toggle source</span>
|
507
|
+
</div>
|
508
|
+
|
509
|
+
|
510
|
+
<div class="method-description">
|
511
|
+
|
512
|
+
|
513
|
+
|
514
|
+
|
515
|
+
|
516
|
+
<div class="method-source-code" id="new-source">
|
517
|
+
<pre>
|
518
|
+
<span class="ruby-comment"># File lib/songkickr/event.rb, line 42</span>
|
519
|
+
<span class="ruby-keyword">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">event_hash</span>)
|
520
|
+
<span class="ruby-ivar">@type</span> = <span class="ruby-identifier">event_hash</span>[<span class="ruby-string">"type"</span>]
|
521
|
+
<span class="ruby-ivar">@location</span> = <span class="ruby-constant">Songkickr</span><span class="ruby-operator">::</span><span class="ruby-constant">Location</span>.<span class="ruby-identifier">new</span> <span class="ruby-identifier">event_hash</span>[<span class="ruby-string">"location"</span>]
|
522
|
+
<span class="ruby-ivar">@status</span> = <span class="ruby-identifier">event_hash</span>[<span class="ruby-string">"status"</span>]
|
523
|
+
<span class="ruby-ivar">@display_name</span> = <span class="ruby-identifier">event_hash</span>[<span class="ruby-string">"displayName"</span>]
|
524
|
+
<span class="ruby-ivar">@venue</span> = <span class="ruby-constant">Songkickr</span><span class="ruby-operator">::</span><span class="ruby-constant">Venue</span>.<span class="ruby-identifier">new</span> <span class="ruby-identifier">event_hash</span>[<span class="ruby-string">"venue"</span>]
|
525
|
+
<span class="ruby-ivar">@start</span> = <span class="ruby-identifier">start_hash_to_datetime</span> <span class="ruby-identifier">event_hash</span>[<span class="ruby-string">"start"</span>]
|
526
|
+
<span class="ruby-ivar">@uri</span> = <span class="ruby-identifier">event_hash</span>[<span class="ruby-string">"uri"</span>]
|
527
|
+
<span class="ruby-ivar">@performances</span> = <span class="ruby-identifier">parse_performance</span> <span class="ruby-identifier">event_hash</span>[<span class="ruby-string">"performance"</span>]
|
528
|
+
<span class="ruby-ivar">@id</span> = <span class="ruby-identifier">event_hash</span>[<span class="ruby-string">"id"</span>]
|
529
|
+
<span class="ruby-ivar">@tickets_uri</span> = <span class="ruby-identifier">event_hash</span>[<span class="ruby-string">"ticketsUri"</span>]
|
530
|
+
<span class="ruby-keyword">end</span></pre>
|
531
|
+
</div><!-- new-source -->
|
532
|
+
|
533
|
+
</div>
|
534
|
+
|
535
|
+
|
536
|
+
|
537
|
+
|
538
|
+
</div><!-- new-method -->
|
539
|
+
|
540
|
+
|
541
|
+
</div><!-- public-class-method-details -->
|
542
|
+
|
543
|
+
</div><!-- 5Buntitled-5D -->
|
544
|
+
|
545
|
+
|
546
|
+
</div><!-- documentation -->
|
547
|
+
|
548
|
+
<div id="validator-badges">
|
549
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
550
|
+
<p><small>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish
|
551
|
+
Rdoc Generator</a> 2</small>.</p>
|
552
|
+
</div>
|
553
|
+
|
554
|
+
</body>
|
555
|
+
</html>
|
556
|
+
|