isimud 0.5.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (78) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +18 -0
  3. data/.rspec +2 -0
  4. data/.ruby-version +1 -0
  5. data/.yardoc/checksums +15 -0
  6. data/.yardoc/object_types +0 -0
  7. data/.yardoc/objects/root.dat +0 -0
  8. data/.yardoc/proxy_types +0 -0
  9. data/Gemfile +23 -0
  10. data/Gemfile.lock +123 -0
  11. data/README.md +218 -0
  12. data/Rakefile +2 -0
  13. data/config.ru +7 -0
  14. data/config/tddium.yml +11 -0
  15. data/doc/Isimud.html +1696 -0
  16. data/doc/Isimud/BunnyClient.html +1004 -0
  17. data/doc/Isimud/Client.html +812 -0
  18. data/doc/Isimud/Event.html +1500 -0
  19. data/doc/Isimud/EventListener.html +1217 -0
  20. data/doc/Isimud/EventObserver.html +367 -0
  21. data/doc/Isimud/EventObserver/ClassMethods.html +292 -0
  22. data/doc/Isimud/Generators.html +117 -0
  23. data/doc/Isimud/Generators/ConfigGenerator.html +192 -0
  24. data/doc/Isimud/Generators/InitializerGenerator.html +192 -0
  25. data/doc/Isimud/Logging.html +230 -0
  26. data/doc/Isimud/ModelWatcher.html +312 -0
  27. data/doc/Isimud/ModelWatcher/ClassMethods.html +511 -0
  28. data/doc/Isimud/Railtie.html +123 -0
  29. data/doc/Isimud/TestClient.html +1003 -0
  30. data/doc/Isimud/TestClient/Queue.html +556 -0
  31. data/doc/_index.html +290 -0
  32. data/doc/class_list.html +58 -0
  33. data/doc/css/common.css +1 -0
  34. data/doc/css/full_list.css +57 -0
  35. data/doc/css/style.css +339 -0
  36. data/doc/file.README.html +338 -0
  37. data/doc/file_list.html +60 -0
  38. data/doc/frames.html +26 -0
  39. data/doc/index.html +338 -0
  40. data/doc/js/app.js +219 -0
  41. data/doc/js/full_list.js +181 -0
  42. data/doc/js/jquery.js +4 -0
  43. data/doc/method_list.html +711 -0
  44. data/doc/top-level-namespace.html +112 -0
  45. data/isimud.gemspec +25 -0
  46. data/lib/isimud.rb +91 -0
  47. data/lib/isimud/bunny_client.rb +95 -0
  48. data/lib/isimud/client.rb +48 -0
  49. data/lib/isimud/event.rb +112 -0
  50. data/lib/isimud/event_listener.rb +200 -0
  51. data/lib/isimud/event_observer.rb +81 -0
  52. data/lib/isimud/logging.rb +11 -0
  53. data/lib/isimud/model_watcher.rb +144 -0
  54. data/lib/isimud/railtie.rb +9 -0
  55. data/lib/isimud/tasks.rb +20 -0
  56. data/lib/isimud/test_client.rb +89 -0
  57. data/lib/isimud/version.rb +3 -0
  58. data/lib/rails/generators/isimud/config_generator.rb +12 -0
  59. data/lib/rails/generators/isimud/initializer_generator.rb +12 -0
  60. data/lib/rails/generators/isimud/templates/initializer.rb +17 -0
  61. data/lib/rails/generators/isimud/templates/isimud.yml +20 -0
  62. data/spec/internal/app/models/admin.rb +2 -0
  63. data/spec/internal/app/models/company.rb +34 -0
  64. data/spec/internal/app/models/user.rb +27 -0
  65. data/spec/internal/config/database.yml +3 -0
  66. data/spec/internal/config/routes.rb +3 -0
  67. data/spec/internal/db/schema.rb +22 -0
  68. data/spec/internal/log/.gitignore +1 -0
  69. data/spec/internal/public/favicon.ico +0 -0
  70. data/spec/isimud/bunny_client_spec.rb +125 -0
  71. data/spec/isimud/event_listener_spec.rb +86 -0
  72. data/spec/isimud/event_observer_spec.rb +32 -0
  73. data/spec/isimud/event_spec.rb +74 -0
  74. data/spec/isimud/model_watcher_spec.rb +189 -0
  75. data/spec/isimud/test_client_spec.rb +28 -0
  76. data/spec/isimud_spec.rb +49 -0
  77. data/spec/spec_helper.rb +55 -0
  78. metadata +195 -0
@@ -0,0 +1,1500 @@
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 http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
+ <title>
7
+ Class: Isimud::Event
8
+
9
+ &mdash; Documentation by YARD 0.8.7.6
10
+
11
+ </title>
12
+
13
+ <link rel="stylesheet" href="../css/style.css" type="text/css" charset="utf-8" />
14
+
15
+ <link rel="stylesheet" href="../css/common.css" type="text/css" charset="utf-8" />
16
+
17
+ <script type="text/javascript" charset="utf-8">
18
+ hasFrames = window.top.frames.main ? true : false;
19
+ relpath = '../';
20
+ framesUrl = "../frames.html#!Isimud/Event.html";
21
+ </script>
22
+
23
+
24
+ <script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
25
+
26
+ <script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
27
+
28
+
29
+ </head>
30
+ <body>
31
+ <div id="header">
32
+ <div id="menu">
33
+
34
+ <a href="../_index.html">Index (E)</a> &raquo;
35
+ <span class='title'><span class='object_link'><a href="../Isimud.html" title="Isimud (module)">Isimud</a></span></span>
36
+ &raquo;
37
+ <span class="title">Event</span>
38
+
39
+
40
+ <div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
41
+ </div>
42
+
43
+ <div id="search">
44
+
45
+ <a class="full_list_link" id="class_list_link"
46
+ href="../class_list.html">
47
+ Class List
48
+ </a>
49
+
50
+ <a class="full_list_link" id="method_list_link"
51
+ href="../method_list.html">
52
+ Method List
53
+ </a>
54
+
55
+ <a class="full_list_link" id="file_list_link"
56
+ href="../file_list.html">
57
+ File List
58
+ </a>
59
+
60
+ </div>
61
+ <div class="clear"></div>
62
+ </div>
63
+
64
+ <iframe id="search_frame"></iframe>
65
+
66
+ <div id="content"><h1>Class: Isimud::Event
67
+
68
+
69
+
70
+ </h1>
71
+
72
+ <dl class="box">
73
+
74
+ <dt class="r1">Inherits:</dt>
75
+ <dd class="r1">
76
+ <span class="inheritName">Object</span>
77
+
78
+ <ul class="fullTree">
79
+ <li>Object</li>
80
+
81
+ <li class="next">Isimud::Event</li>
82
+
83
+ </ul>
84
+ <a href="#" class="inheritanceTree">show all</a>
85
+
86
+ </dd>
87
+
88
+
89
+
90
+
91
+
92
+
93
+ <dt class="r2">Includes:</dt>
94
+ <dd class="r2"><span class='object_link'><a href="Logging.html" title="Isimud::Logging (module)">Logging</a></span></dd>
95
+
96
+
97
+
98
+
99
+
100
+ <dt class="r1 last">Defined in:</dt>
101
+ <dd class="r1 last">lib/isimud/event.rb</dd>
102
+
103
+ </dl>
104
+ <div class="clear"></div>
105
+
106
+
107
+ <h2>Constant Summary</h2>
108
+
109
+ <dl class="constants">
110
+
111
+ <dt id="DEFAULT_TYPE-constant" class="">DEFAULT_TYPE =
112
+
113
+ </dt>
114
+ <dd><pre class="code"><span class='symbol'>:model</span></pre></dd>
115
+
116
+ </dl>
117
+
118
+
119
+
120
+
121
+
122
+ <h2>Instance Attribute Summary <small>(<a href="#" class="summary_toggle">collapse</a>)</small></h2>
123
+ <ul class="summary">
124
+
125
+ <li class="public ">
126
+ <span class="summary_signature">
127
+
128
+ <a href="#action-instance_method" title="#action (instance method)">- (Object) <strong>action</strong> </a>
129
+
130
+
131
+
132
+ </span>
133
+
134
+
135
+
136
+
137
+
138
+
139
+
140
+
141
+
142
+
143
+
144
+
145
+ <span class="summary_desc"><div class='inline'>
146
+ <p>Returns the value of attribute action.</p>
147
+ </div></span>
148
+
149
+ </li>
150
+
151
+
152
+ <li class="public ">
153
+ <span class="summary_signature">
154
+
155
+ <a href="#eventful_id-instance_method" title="#eventful_id (instance method)">- (Object) <strong>eventful_id</strong> </a>
156
+
157
+
158
+
159
+ </span>
160
+
161
+
162
+
163
+
164
+
165
+
166
+
167
+
168
+
169
+
170
+
171
+
172
+ <span class="summary_desc"><div class='inline'>
173
+ <p>Returns the value of attribute eventful_id.</p>
174
+ </div></span>
175
+
176
+ </li>
177
+
178
+
179
+ <li class="public ">
180
+ <span class="summary_signature">
181
+
182
+ <a href="#eventful_type-instance_method" title="#eventful_type (instance method)">- (Object) <strong>eventful_type</strong> </a>
183
+
184
+
185
+
186
+ </span>
187
+
188
+
189
+
190
+
191
+
192
+
193
+
194
+
195
+
196
+
197
+
198
+
199
+ <span class="summary_desc"><div class='inline'>
200
+ <p>Returns the value of attribute eventful_type.</p>
201
+ </div></span>
202
+
203
+ </li>
204
+
205
+
206
+ <li class="public ">
207
+ <span class="summary_signature">
208
+
209
+ <a href="#exchange-instance_method" title="#exchange (instance method)">- (Object) <strong>exchange</strong> </a>
210
+
211
+
212
+
213
+ </span>
214
+
215
+
216
+
217
+
218
+
219
+
220
+
221
+
222
+
223
+
224
+
225
+
226
+ <span class="summary_desc"><div class='inline'></div></span>
227
+
228
+ </li>
229
+
230
+
231
+ <li class="public ">
232
+ <span class="summary_signature">
233
+
234
+ <a href="#occurred_at-instance_method" title="#occurred_at (instance method)">- (Object) <strong>occurred_at</strong> </a>
235
+
236
+
237
+
238
+ </span>
239
+
240
+
241
+
242
+
243
+
244
+
245
+
246
+
247
+
248
+
249
+
250
+
251
+ <span class="summary_desc"><div class='inline'>
252
+ <p>Returns the value of attribute occurred_at.</p>
253
+ </div></span>
254
+
255
+ </li>
256
+
257
+
258
+ <li class="public ">
259
+ <span class="summary_signature">
260
+
261
+ <a href="#parameters-instance_method" title="#parameters (instance method)">- (Object) <strong>parameters</strong> </a>
262
+
263
+
264
+
265
+ </span>
266
+
267
+
268
+
269
+
270
+
271
+
272
+
273
+
274
+
275
+
276
+
277
+
278
+ <span class="summary_desc"><div class='inline'>
279
+ <p>Returns the value of attribute parameters.</p>
280
+ </div></span>
281
+
282
+ </li>
283
+
284
+
285
+ <li class="public ">
286
+ <span class="summary_signature">
287
+
288
+ <a href="#type-instance_method" title="#type (instance method)">- (Object) <strong>type</strong> </a>
289
+
290
+
291
+
292
+ </span>
293
+
294
+
295
+
296
+
297
+
298
+
299
+
300
+
301
+
302
+
303
+
304
+
305
+ <span class="summary_desc"><div class='inline'>
306
+ <p>Returns the value of attribute type.</p>
307
+ </div></span>
308
+
309
+ </li>
310
+
311
+
312
+ <li class="public ">
313
+ <span class="summary_signature">
314
+
315
+ <a href="#user_id-instance_method" title="#user_id (instance method)">- (Object) <strong>user_id</strong> </a>
316
+
317
+
318
+
319
+ </span>
320
+
321
+
322
+
323
+
324
+
325
+
326
+
327
+
328
+
329
+
330
+
331
+
332
+ <span class="summary_desc"><div class='inline'>
333
+ <p>Returns the value of attribute user_id.</p>
334
+ </div></span>
335
+
336
+ </li>
337
+
338
+
339
+ </ul>
340
+
341
+
342
+
343
+
344
+
345
+ <h2>
346
+ Class Method Summary
347
+ <small>(<a href="#" class="summary_toggle">collapse</a>)</small>
348
+ </h2>
349
+
350
+ <ul class="summary">
351
+
352
+ <li class="public ">
353
+ <span class="summary_signature">
354
+
355
+ <a href="#dispatch-class_method" title="dispatch (class method)">+ (Object) <strong>dispatch</strong> </a>
356
+
357
+
358
+
359
+ </span>
360
+
361
+
362
+
363
+
364
+
365
+
366
+
367
+
368
+
369
+ <span class="summary_desc"><div class='inline'></div></span>
370
+
371
+ </li>
372
+
373
+
374
+ <li class="public ">
375
+ <span class="summary_signature">
376
+
377
+ <a href="#parse-class_method" title="parse (class method)">+ (Object) <strong>parse</strong>(data) </a>
378
+
379
+
380
+
381
+ </span>
382
+
383
+
384
+
385
+
386
+
387
+
388
+
389
+
390
+
391
+ <span class="summary_desc"><div class='inline'></div></span>
392
+
393
+ </li>
394
+
395
+
396
+ <li class="public ">
397
+ <span class="summary_signature">
398
+
399
+ <a href="#publish-class_method" title="publish (class method)">+ (Object) <strong>publish</strong>(*args) </a>
400
+
401
+
402
+
403
+ </span>
404
+
405
+
406
+
407
+
408
+
409
+
410
+
411
+
412
+
413
+ <span class="summary_desc"><div class='inline'></div></span>
414
+
415
+ </li>
416
+
417
+
418
+ </ul>
419
+
420
+ <h2>
421
+ Instance Method Summary
422
+ <small>(<a href="#" class="summary_toggle">collapse</a>)</small>
423
+ </h2>
424
+
425
+ <ul class="summary">
426
+
427
+ <li class="public ">
428
+ <span class="summary_signature">
429
+
430
+ <a href="#as_json-instance_method" title="#as_json (instance method)">- (Hash) <strong>as_json</strong>(options = {}) </a>
431
+
432
+
433
+
434
+ </span>
435
+
436
+
437
+
438
+
439
+
440
+
441
+
442
+
443
+
444
+ <span class="summary_desc"><div class='inline'>
445
+ <p>Return hash of data to be serialized to JSON.</p>
446
+ </div></span>
447
+
448
+ </li>
449
+
450
+
451
+ <li class="public ">
452
+ <span class="summary_signature">
453
+
454
+ <a href="#initialize-instance_method" title="#initialize (instance method)">- (Event) <strong>initialize</strong>(*args) </a>
455
+
456
+
457
+
458
+ </span>
459
+
460
+
461
+ <span class="note title constructor">constructor</span>
462
+
463
+
464
+
465
+
466
+
467
+
468
+
469
+
470
+ <span class="summary_desc"><div class='inline'>
471
+ <p>Initialize a new Event.</p>
472
+ </div></span>
473
+
474
+ </li>
475
+
476
+
477
+ <li class="public ">
478
+ <span class="summary_signature">
479
+
480
+ <a href="#publish-instance_method" title="#publish (instance method)">- (Object) <strong>publish</strong> </a>
481
+
482
+
483
+
484
+ </span>
485
+
486
+
487
+
488
+
489
+
490
+
491
+
492
+
493
+
494
+ <span class="summary_desc"><div class='inline'></div></span>
495
+
496
+ </li>
497
+
498
+
499
+ <li class="public ">
500
+ <span class="summary_signature">
501
+
502
+ <a href="#routing_key-instance_method" title="#routing_key (instance method)">- (Object) <strong>routing_key</strong> </a>
503
+
504
+
505
+
506
+ </span>
507
+
508
+
509
+
510
+
511
+
512
+
513
+
514
+
515
+
516
+ <span class="summary_desc"><div class='inline'></div></span>
517
+
518
+ </li>
519
+
520
+
521
+ <li class="public ">
522
+ <span class="summary_signature">
523
+
524
+ <a href="#serialize-instance_method" title="#serialize (instance method)">- (Object) <strong>serialize</strong> </a>
525
+
526
+
527
+
528
+ </span>
529
+
530
+
531
+
532
+
533
+
534
+
535
+
536
+
537
+
538
+ <span class="summary_desc"><div class='inline'></div></span>
539
+
540
+ </li>
541
+
542
+
543
+ </ul>
544
+
545
+
546
+
547
+
548
+
549
+
550
+
551
+
552
+
553
+
554
+
555
+ <h3 class="inherited">Methods included from <span class='object_link'><a href="Logging.html" title="Isimud::Logging (module)">Logging</a></span></h3>
556
+ <p class="inherited"><span class='object_link'><a href="Logging.html#log-instance_method" title="Isimud::Logging#log (method)">#log</a></span>, <span class='object_link'><a href="Logging.html#logger-instance_method" title="Isimud::Logging#logger (method)">#logger</a></span></p>
557
+ <div id="constructor_details" class="method_details_list">
558
+ <h2>Constructor Details</h2>
559
+
560
+ <div class="method_details first">
561
+ <h3 class="signature first" id="initialize-instance_method">
562
+
563
+
564
+ <span class="overload">- (<tt><span class='object_link'><a href="" title="Isimud::Event (class)">Event</a></span></tt>) <strong>Event.new</strong>(user, eventful, parameters) </span>
565
+
566
+ <span class="overload">- (<tt><span class='object_link'><a href="" title="Isimud::Event (class)">Event</a></span></tt>) <strong>Event.new</strong>(attributes) </span>
567
+
568
+
569
+
570
+
571
+
572
+
573
+ </h3><div class="docstring">
574
+ <div class="discussion">
575
+
576
+ <p>Initialize a new Event</p>
577
+
578
+
579
+ </div>
580
+ </div>
581
+ <div class="tags">
582
+
583
+ <p class="tag_title">Overloads:</p>
584
+ <ul class="overload">
585
+
586
+
587
+ <li class="overload_item">
588
+ <span class="signature">- (<tt><span class='object_link'><a href="" title="Isimud::Event (class)">Event</a></span></tt>) <strong>Event.new</strong>(user, eventful, parameters) </span>
589
+ <div class="docstring">
590
+ <div class="discussion">
591
+
592
+ <p>@<a href="#id">param</a> user user associated by the event @<a
593
+ href="ActiveRecord::Base">param</a> eventful object associated with event
594
+ @<a href="Hash">param</a> parameters optional additional parameters</p>
595
+
596
+
597
+ </div>
598
+ </div>
599
+ <div class="tags">
600
+
601
+
602
+ </div>
603
+ </li>
604
+
605
+
606
+ <li class="overload_item">
607
+ <span class="signature">- (<tt><span class='object_link'><a href="" title="Isimud::Event (class)">Event</a></span></tt>) <strong>Event.new</strong>(attributes) </span>
608
+ <div class="docstring">
609
+ <div class="discussion">
610
+
611
+ <p>@<a href="Hash">param</a> attributes event attributes</p>
612
+
613
+
614
+ </div>
615
+ </div>
616
+ <div class="tags">
617
+
618
+
619
+
620
+
621
+ <p class="tag_title">Options Hash (<tt>attributes</tt>):</p>
622
+ <ul class="option">
623
+
624
+ <li>
625
+ <span class="name">:user_id</span>
626
+ <span class="type">(<tt>Integer</tt>)</span>
627
+ <span class="default">
628
+
629
+ </span>
630
+
631
+ &mdash; <div class='inline'>
632
+ <p>ID of User associated with event</p>
633
+ </div>
634
+
635
+ </li>
636
+
637
+ <li>
638
+ <span class="name">:eventful_type</span>
639
+ <span class="type">(<tt>String</tt>)</span>
640
+ <span class="default">
641
+
642
+ </span>
643
+
644
+ &mdash; <div class='inline'>
645
+ <p>class of object associated with event</p>
646
+ </div>
647
+
648
+ </li>
649
+
650
+ <li>
651
+ <span class="name">:eventful_id</span>
652
+ <span class="type">(<tt>Integer</tt>)</span>
653
+ <span class="default">
654
+
655
+ </span>
656
+
657
+ &mdash; <div class='inline'>
658
+ <p>id of object associated with event</p>
659
+ </div>
660
+
661
+ </li>
662
+
663
+ <li>
664
+ <span class="name">:exchange</span>
665
+ <span class="type">(<tt>String</tt>)</span>
666
+ <span class="default">
667
+
668
+ &mdash; default:
669
+ <tt>Isimud.events_exchange</tt>
670
+
671
+ </span>
672
+
673
+ &mdash; <div class='inline'>
674
+ <p>exchange for publishing event</p>
675
+ </div>
676
+
677
+ </li>
678
+
679
+ <li>
680
+ <span class="name">:eventful</span>
681
+ <span class="type">(<tt>ActiveRecord::Base</tt>)</span>
682
+ <span class="default">
683
+
684
+ </span>
685
+
686
+ &mdash; <div class='inline'>
687
+ <p>object associated with event. This sets :eventful_type and :eventful_id.</p>
688
+ </div>
689
+
690
+ </li>
691
+
692
+ <li>
693
+ <span class="name">:type</span>
694
+ <span class="type">(<tt>String</tt>, <tt>Symbol</tt>)</span>
695
+ <span class="default">
696
+
697
+ &mdash; default:
698
+ <tt>:model</tt>
699
+
700
+ </span>
701
+
702
+ &mdash; <div class='inline'>
703
+ <p>event type</p>
704
+ </div>
705
+
706
+ </li>
707
+
708
+ <li>
709
+ <span class="name">:action</span>
710
+ <span class="type">(<tt>String</tt>)</span>
711
+ <span class="default">
712
+
713
+ </span>
714
+
715
+ &mdash; <div class='inline'>
716
+ <p>event action</p>
717
+ </div>
718
+
719
+ </li>
720
+
721
+ <li>
722
+ <span class="name">:occurred_at</span>
723
+ <span class="type">(<tt>Time</tt>)</span>
724
+ <span class="default">
725
+
726
+ &mdash; default:
727
+ <tt>Time.now</tt>
728
+
729
+ </span>
730
+
731
+ &mdash; <div class='inline'>
732
+ <p>date and time event occurred</p>
733
+ </div>
734
+
735
+ </li>
736
+
737
+ <li>
738
+ <span class="name">:parameters</span>
739
+ <span class="type">(<tt>Hash</tt>)</span>
740
+ <span class="default">
741
+
742
+ </span>
743
+
744
+ &mdash; <div class='inline'>
745
+ <p>additional parameters</p>
746
+ </div>
747
+
748
+ </li>
749
+
750
+ </ul>
751
+
752
+
753
+
754
+ </div>
755
+ </li>
756
+
757
+ </ul>
758
+
759
+
760
+ </div><table class="source_code">
761
+ <tr>
762
+ <td>
763
+ <pre class="lines">
764
+
765
+
766
+ 27
767
+ 28
768
+ 29
769
+ 30
770
+ 31
771
+ 32
772
+ 33
773
+ 34
774
+ 35
775
+ 36
776
+ 37
777
+ 38
778
+ 39
779
+ 40
780
+ 41
781
+ 42
782
+ 43
783
+ 44
784
+ 45
785
+ 46
786
+ 47
787
+ 48
788
+ 49
789
+ 50
790
+ 51
791
+ 52
792
+ 53
793
+ 54
794
+ 55
795
+ 56
796
+ 57
797
+ 58
798
+ 59</pre>
799
+ </td>
800
+ <td>
801
+ <pre class="code"><span class="info file"># File 'lib/isimud/event.rb', line 27</span>
802
+
803
+ <span class='kw'>def</span> <span class='id identifier rubyid_initialize'>initialize</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span>
804
+ <span class='id identifier rubyid_options'>options</span> <span class='op'>=</span> <span class='id identifier rubyid_args'>args</span><span class='period'>.</span><span class='id identifier rubyid_extract_options!'>extract_options!</span><span class='period'>.</span><span class='id identifier rubyid_with_indifferent_access'>with_indifferent_access</span>
805
+
806
+ <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_type'>type</span> <span class='op'>=</span> <span class='id identifier rubyid_options'>options</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='symbol'>:type</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_try'>try</span><span class='lparen'>(</span><span class='symbol'>:to_sym</span><span class='rparen'>)</span> <span class='op'>||</span> <span class='const'>DEFAULT_TYPE</span>
807
+ <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_exchange'>exchange</span> <span class='op'>=</span> <span class='id identifier rubyid_options'>options</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='symbol'>:exchange</span><span class='rparen'>)</span>
808
+ <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_action'>action</span> <span class='op'>=</span> <span class='id identifier rubyid_options'>options</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='symbol'>:action</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_try'>try</span><span class='lparen'>(</span><span class='symbol'>:to_sym</span><span class='rparen'>)</span>
809
+ <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_user_id'>user_id</span> <span class='op'>=</span> <span class='id identifier rubyid_options'>options</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='symbol'>:user_id</span><span class='rparen'>)</span>
810
+ <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_occurred_at'>occurred_at</span> <span class='op'>=</span> <span class='kw'>if</span> <span class='lparen'>(</span><span class='id identifier rubyid_occurred'>occurred</span> <span class='op'>=</span> <span class='id identifier rubyid_options'>options</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='symbol'>:occurred_at</span><span class='rparen'>)</span><span class='rparen'>)</span>
811
+ <span class='id identifier rubyid_occurred'>occurred</span><span class='period'>.</span><span class='id identifier rubyid_kind_of?'>kind_of?</span><span class='lparen'>(</span><span class='const'>String</span><span class='rparen'>)</span> <span class='op'>?</span> <span class='const'>Time</span><span class='period'>.</span><span class='id identifier rubyid_parse'>parse</span><span class='lparen'>(</span><span class='id identifier rubyid_occurred'>occurred</span><span class='rparen'>)</span> <span class='op'>:</span> <span class='id identifier rubyid_occurred'>occurred</span>
812
+ <span class='kw'>else</span>
813
+ <span class='const'>Time</span><span class='period'>.</span><span class='id identifier rubyid_now'>now</span><span class='period'>.</span><span class='id identifier rubyid_utc'>utc</span>
814
+ <span class='kw'>end</span>
815
+
816
+ <span class='id identifier rubyid_eventful_object'>eventful_object</span> <span class='op'>=</span> <span class='id identifier rubyid_options'>options</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='symbol'>:eventful</span><span class='rparen'>)</span>
817
+
818
+ <span class='kw'>if</span> <span class='id identifier rubyid_args'>args</span><span class='period'>.</span><span class='id identifier rubyid_length'>length</span> <span class='op'>&gt;</span> <span class='int'>0</span>
819
+ <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_parameters'>parameters</span> <span class='op'>=</span> <span class='id identifier rubyid_options'>options</span>
820
+ <span class='kw'>if</span> <span class='lparen'>(</span><span class='id identifier rubyid_user'>user</span> <span class='op'>=</span> <span class='id identifier rubyid_args'>args</span><span class='period'>.</span><span class='id identifier rubyid_shift'>shift</span><span class='rparen'>)</span>
821
+ <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_user_id'>user_id</span> <span class='op'>=</span> <span class='id identifier rubyid_user'>user</span><span class='period'>.</span><span class='id identifier rubyid_id'>id</span>
822
+ <span class='kw'>end</span>
823
+ <span class='id identifier rubyid_eventful_object'>eventful_object</span> <span class='op'>||=</span> <span class='id identifier rubyid_args'>args</span><span class='period'>.</span><span class='id identifier rubyid_shift'>shift</span>
824
+ <span class='kw'>end</span>
825
+
826
+ <span class='kw'>if</span> <span class='id identifier rubyid_eventful_object'>eventful_object</span>
827
+ <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_eventful_type'>eventful_type</span> <span class='op'>=</span> <span class='id identifier rubyid_eventful_object'>eventful_object</span><span class='period'>.</span><span class='id identifier rubyid_class'>class</span><span class='period'>.</span><span class='id identifier rubyid_base_class'>base_class</span><span class='period'>.</span><span class='id identifier rubyid_name'>name</span>
828
+ <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_eventful_id'>eventful_id</span> <span class='op'>=</span> <span class='id identifier rubyid_eventful_object'>eventful_object</span><span class='period'>.</span><span class='id identifier rubyid_id'>id</span>
829
+ <span class='kw'>else</span>
830
+ <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_eventful_type'>eventful_type</span> <span class='op'>=</span> <span class='id identifier rubyid_options'>options</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='symbol'>:eventful_type</span><span class='rparen'>)</span>
831
+ <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_eventful_id'>eventful_id</span> <span class='op'>=</span> <span class='id identifier rubyid_options'>options</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='symbol'>:eventful_id</span><span class='rparen'>)</span>
832
+ <span class='kw'>end</span>
833
+
834
+ <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_parameters'>parameters</span> <span class='op'>=</span> <span class='id identifier rubyid_options'>options</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='symbol'>:parameters</span><span class='rparen'>)</span> <span class='op'>||</span> <span class='id identifier rubyid_options'>options</span>
835
+ <span class='kw'>end</span></pre>
836
+ </td>
837
+ </tr>
838
+ </table>
839
+ </div>
840
+
841
+ </div>
842
+
843
+ <div id="instance_attr_details" class="attr_details">
844
+ <h2>Instance Attribute Details</h2>
845
+
846
+
847
+ <span id="action=-instance_method"></span>
848
+ <div class="method_details first">
849
+ <h3 class="signature first" id="action-instance_method">
850
+
851
+ - (<tt>Object</tt>) <strong>action</strong>
852
+
853
+
854
+
855
+
856
+
857
+ </h3><div class="docstring">
858
+ <div class="discussion">
859
+
860
+ <p>Returns the value of attribute action</p>
861
+
862
+
863
+ </div>
864
+ </div>
865
+ <div class="tags">
866
+
867
+
868
+ </div><table class="source_code">
869
+ <tr>
870
+ <td>
871
+ <pre class="lines">
872
+
873
+
874
+ 6
875
+ 7
876
+ 8</pre>
877
+ </td>
878
+ <td>
879
+ <pre class="code"><span class="info file"># File 'lib/isimud/event.rb', line 6</span>
880
+
881
+ <span class='kw'>def</span> <span class='id identifier rubyid_action'>action</span>
882
+ <span class='ivar'>@action</span>
883
+ <span class='kw'>end</span></pre>
884
+ </td>
885
+ </tr>
886
+ </table>
887
+ </div>
888
+
889
+
890
+ <span id="eventful_id=-instance_method"></span>
891
+ <div class="method_details ">
892
+ <h3 class="signature " id="eventful_id-instance_method">
893
+
894
+ - (<tt>Object</tt>) <strong>eventful_id</strong>
895
+
896
+
897
+
898
+
899
+
900
+ </h3><div class="docstring">
901
+ <div class="discussion">
902
+
903
+ <p>Returns the value of attribute eventful_id</p>
904
+
905
+
906
+ </div>
907
+ </div>
908
+ <div class="tags">
909
+
910
+
911
+ </div><table class="source_code">
912
+ <tr>
913
+ <td>
914
+ <pre class="lines">
915
+
916
+
917
+ 6
918
+ 7
919
+ 8</pre>
920
+ </td>
921
+ <td>
922
+ <pre class="code"><span class="info file"># File 'lib/isimud/event.rb', line 6</span>
923
+
924
+ <span class='kw'>def</span> <span class='id identifier rubyid_eventful_id'>eventful_id</span>
925
+ <span class='ivar'>@eventful_id</span>
926
+ <span class='kw'>end</span></pre>
927
+ </td>
928
+ </tr>
929
+ </table>
930
+ </div>
931
+
932
+
933
+ <span id="eventful_type=-instance_method"></span>
934
+ <div class="method_details ">
935
+ <h3 class="signature " id="eventful_type-instance_method">
936
+
937
+ - (<tt>Object</tt>) <strong>eventful_type</strong>
938
+
939
+
940
+
941
+
942
+
943
+ </h3><div class="docstring">
944
+ <div class="discussion">
945
+
946
+ <p>Returns the value of attribute eventful_type</p>
947
+
948
+
949
+ </div>
950
+ </div>
951
+ <div class="tags">
952
+
953
+
954
+ </div><table class="source_code">
955
+ <tr>
956
+ <td>
957
+ <pre class="lines">
958
+
959
+
960
+ 6
961
+ 7
962
+ 8</pre>
963
+ </td>
964
+ <td>
965
+ <pre class="code"><span class="info file"># File 'lib/isimud/event.rb', line 6</span>
966
+
967
+ <span class='kw'>def</span> <span class='id identifier rubyid_eventful_type'>eventful_type</span>
968
+ <span class='ivar'>@eventful_type</span>
969
+ <span class='kw'>end</span></pre>
970
+ </td>
971
+ </tr>
972
+ </table>
973
+ </div>
974
+
975
+
976
+ <span id="exchange=-instance_method"></span>
977
+ <div class="method_details ">
978
+ <h3 class="signature " id="exchange-instance_method">
979
+
980
+ - (<tt>Object</tt>) <strong>exchange</strong>
981
+
982
+
983
+
984
+
985
+
986
+ </h3><table class="source_code">
987
+ <tr>
988
+ <td>
989
+ <pre class="lines">
990
+
991
+
992
+ 61
993
+ 62
994
+ 63</pre>
995
+ </td>
996
+ <td>
997
+ <pre class="code"><span class="info file"># File 'lib/isimud/event.rb', line 61</span>
998
+
999
+ <span class='kw'>def</span> <span class='id identifier rubyid_exchange'>exchange</span>
1000
+ <span class='ivar'>@exchange</span> <span class='op'>||</span> <span class='const'>Isimud</span><span class='period'>.</span><span class='id identifier rubyid_events_exchange'>events_exchange</span>
1001
+ <span class='kw'>end</span></pre>
1002
+ </td>
1003
+ </tr>
1004
+ </table>
1005
+ </div>
1006
+
1007
+
1008
+ <span id="occurred_at=-instance_method"></span>
1009
+ <div class="method_details ">
1010
+ <h3 class="signature " id="occurred_at-instance_method">
1011
+
1012
+ - (<tt>Object</tt>) <strong>occurred_at</strong>
1013
+
1014
+
1015
+
1016
+
1017
+
1018
+ </h3><div class="docstring">
1019
+ <div class="discussion">
1020
+
1021
+ <p>Returns the value of attribute occurred_at</p>
1022
+
1023
+
1024
+ </div>
1025
+ </div>
1026
+ <div class="tags">
1027
+
1028
+
1029
+ </div><table class="source_code">
1030
+ <tr>
1031
+ <td>
1032
+ <pre class="lines">
1033
+
1034
+
1035
+ 6
1036
+ 7
1037
+ 8</pre>
1038
+ </td>
1039
+ <td>
1040
+ <pre class="code"><span class="info file"># File 'lib/isimud/event.rb', line 6</span>
1041
+
1042
+ <span class='kw'>def</span> <span class='id identifier rubyid_occurred_at'>occurred_at</span>
1043
+ <span class='ivar'>@occurred_at</span>
1044
+ <span class='kw'>end</span></pre>
1045
+ </td>
1046
+ </tr>
1047
+ </table>
1048
+ </div>
1049
+
1050
+
1051
+ <span id="parameters=-instance_method"></span>
1052
+ <div class="method_details ">
1053
+ <h3 class="signature " id="parameters-instance_method">
1054
+
1055
+ - (<tt>Object</tt>) <strong>parameters</strong>
1056
+
1057
+
1058
+
1059
+
1060
+
1061
+ </h3><div class="docstring">
1062
+ <div class="discussion">
1063
+
1064
+ <p>Returns the value of attribute parameters</p>
1065
+
1066
+
1067
+ </div>
1068
+ </div>
1069
+ <div class="tags">
1070
+
1071
+
1072
+ </div><table class="source_code">
1073
+ <tr>
1074
+ <td>
1075
+ <pre class="lines">
1076
+
1077
+
1078
+ 6
1079
+ 7
1080
+ 8</pre>
1081
+ </td>
1082
+ <td>
1083
+ <pre class="code"><span class="info file"># File 'lib/isimud/event.rb', line 6</span>
1084
+
1085
+ <span class='kw'>def</span> <span class='id identifier rubyid_parameters'>parameters</span>
1086
+ <span class='ivar'>@parameters</span>
1087
+ <span class='kw'>end</span></pre>
1088
+ </td>
1089
+ </tr>
1090
+ </table>
1091
+ </div>
1092
+
1093
+
1094
+ <span id="type=-instance_method"></span>
1095
+ <div class="method_details ">
1096
+ <h3 class="signature " id="type-instance_method">
1097
+
1098
+ - (<tt>Object</tt>) <strong>type</strong>
1099
+
1100
+
1101
+
1102
+
1103
+
1104
+ </h3><div class="docstring">
1105
+ <div class="discussion">
1106
+
1107
+ <p>Returns the value of attribute type</p>
1108
+
1109
+
1110
+ </div>
1111
+ </div>
1112
+ <div class="tags">
1113
+
1114
+
1115
+ </div><table class="source_code">
1116
+ <tr>
1117
+ <td>
1118
+ <pre class="lines">
1119
+
1120
+
1121
+ 6
1122
+ 7
1123
+ 8</pre>
1124
+ </td>
1125
+ <td>
1126
+ <pre class="code"><span class="info file"># File 'lib/isimud/event.rb', line 6</span>
1127
+
1128
+ <span class='kw'>def</span> <span class='id identifier rubyid_type'>type</span>
1129
+ <span class='ivar'>@type</span>
1130
+ <span class='kw'>end</span></pre>
1131
+ </td>
1132
+ </tr>
1133
+ </table>
1134
+ </div>
1135
+
1136
+
1137
+ <span id="user_id=-instance_method"></span>
1138
+ <div class="method_details ">
1139
+ <h3 class="signature " id="user_id-instance_method">
1140
+
1141
+ - (<tt>Object</tt>) <strong>user_id</strong>
1142
+
1143
+
1144
+
1145
+
1146
+
1147
+ </h3><div class="docstring">
1148
+ <div class="discussion">
1149
+
1150
+ <p>Returns the value of attribute user_id</p>
1151
+
1152
+
1153
+ </div>
1154
+ </div>
1155
+ <div class="tags">
1156
+
1157
+
1158
+ </div><table class="source_code">
1159
+ <tr>
1160
+ <td>
1161
+ <pre class="lines">
1162
+
1163
+
1164
+ 6
1165
+ 7
1166
+ 8</pre>
1167
+ </td>
1168
+ <td>
1169
+ <pre class="code"><span class="info file"># File 'lib/isimud/event.rb', line 6</span>
1170
+
1171
+ <span class='kw'>def</span> <span class='id identifier rubyid_user_id'>user_id</span>
1172
+ <span class='ivar'>@user_id</span>
1173
+ <span class='kw'>end</span></pre>
1174
+ </td>
1175
+ </tr>
1176
+ </table>
1177
+ </div>
1178
+
1179
+ </div>
1180
+
1181
+
1182
+ <div id="class_method_details" class="method_details_list">
1183
+ <h2>Class Method Details</h2>
1184
+
1185
+
1186
+ <div class="method_details first">
1187
+ <h3 class="signature first" id="dispatch-class_method">
1188
+
1189
+ + (<tt>Object</tt>) <strong>dispatch</strong>
1190
+
1191
+
1192
+
1193
+
1194
+
1195
+ </h3><table class="source_code">
1196
+ <tr>
1197
+ <td>
1198
+ <pre class="lines">
1199
+
1200
+
1201
+ 94
1202
+ 95
1203
+ 96</pre>
1204
+ </td>
1205
+ <td>
1206
+ <pre class="code"><span class="info file"># File 'lib/isimud/event.rb', line 94</span>
1207
+
1208
+ <span class='kw'>def</span> <span class='id identifier rubyid_publish'>publish</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span>
1209
+ <span class='const'>Event</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_publish'>publish</span>
1210
+ <span class='kw'>end</span></pre>
1211
+ </td>
1212
+ </tr>
1213
+ </table>
1214
+ </div>
1215
+
1216
+ <div class="method_details ">
1217
+ <h3 class="signature " id="parse-class_method">
1218
+
1219
+ + (<tt>Object</tt>) <strong>parse</strong>(data)
1220
+
1221
+
1222
+
1223
+
1224
+
1225
+ </h3><table class="source_code">
1226
+ <tr>
1227
+ <td>
1228
+ <pre class="lines">
1229
+
1230
+
1231
+ 86
1232
+ 87
1233
+ 88</pre>
1234
+ </td>
1235
+ <td>
1236
+ <pre class="code"><span class="info file"># File 'lib/isimud/event.rb', line 86</span>
1237
+
1238
+ <span class='kw'>def</span> <span class='id identifier rubyid_parse'>parse</span><span class='lparen'>(</span><span class='id identifier rubyid_data'>data</span><span class='rparen'>)</span>
1239
+ <span class='const'>Event</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='const'>JSON</span><span class='period'>.</span><span class='id identifier rubyid_parse'>parse</span><span class='lparen'>(</span><span class='id identifier rubyid_data'>data</span><span class='rparen'>)</span><span class='rparen'>)</span>
1240
+ <span class='kw'>end</span></pre>
1241
+ </td>
1242
+ </tr>
1243
+ </table>
1244
+ </div>
1245
+
1246
+ <div class="method_details ">
1247
+ <h3 class="signature " id="publish-class_method">
1248
+
1249
+ + (<tt>Object</tt>) <strong>publish</strong>(*args)
1250
+
1251
+
1252
+
1253
+
1254
+
1255
+ </h3><table class="source_code">
1256
+ <tr>
1257
+ <td>
1258
+ <pre class="lines">
1259
+
1260
+
1261
+ 90
1262
+ 91
1263
+ 92</pre>
1264
+ </td>
1265
+ <td>
1266
+ <pre class="code"><span class="info file"># File 'lib/isimud/event.rb', line 90</span>
1267
+
1268
+ <span class='kw'>def</span> <span class='id identifier rubyid_publish'>publish</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span>
1269
+ <span class='const'>Event</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_publish'>publish</span>
1270
+ <span class='kw'>end</span></pre>
1271
+ </td>
1272
+ </tr>
1273
+ </table>
1274
+ </div>
1275
+
1276
+ </div>
1277
+
1278
+ <div id="instance_method_details" class="method_details_list">
1279
+ <h2>Instance Method Details</h2>
1280
+
1281
+
1282
+ <div class="method_details first">
1283
+ <h3 class="signature first" id="as_json-instance_method">
1284
+
1285
+ - (<tt>Hash</tt>) <strong>as_json</strong>(options = {})
1286
+
1287
+
1288
+
1289
+
1290
+
1291
+ </h3><div class="docstring">
1292
+ <div class="discussion">
1293
+
1294
+ <p>Return hash of data to be serialized to JSON</p>
1295
+
1296
+
1297
+ </div>
1298
+ </div>
1299
+ <div class="tags">
1300
+ <p class="tag_title">Parameters:</p>
1301
+ <ul class="param">
1302
+
1303
+ <li>
1304
+
1305
+ <span class='name'>options</span>
1306
+
1307
+
1308
+ <span class='type'>(<tt>Hash</tt>)</span>
1309
+
1310
+
1311
+ <em class="default">(defaults to: <tt>{}</tt>)</em>
1312
+
1313
+
1314
+ &mdash;
1315
+ <div class='inline'>
1316
+ <p>a customizable set of options</p>
1317
+ </div>
1318
+
1319
+ </li>
1320
+
1321
+ </ul>
1322
+
1323
+
1324
+
1325
+
1326
+ <p class="tag_title">Options Hash (<tt>options</tt>):</p>
1327
+ <ul class="option">
1328
+
1329
+ <li>
1330
+ <span class="name">:omit_parameters</span>
1331
+ <span class="type">(<tt>Boolean</tt>)</span>
1332
+ <span class="default">
1333
+
1334
+ </span>
1335
+
1336
+ &mdash; <div class='inline'>
1337
+ <p>when set, do not include parameters in data</p>
1338
+ </div>
1339
+
1340
+ </li>
1341
+
1342
+ </ul>
1343
+
1344
+
1345
+ <p class="tag_title">Returns:</p>
1346
+ <ul class="return">
1347
+
1348
+ <li>
1349
+
1350
+
1351
+ <span class='type'>(<tt>Hash</tt>)</span>
1352
+
1353
+
1354
+
1355
+ &mdash;
1356
+ <div class='inline'>
1357
+ <p>data to serialize</p>
1358
+ </div>
1359
+
1360
+ </li>
1361
+
1362
+ </ul>
1363
+
1364
+ </div><table class="source_code">
1365
+ <tr>
1366
+ <td>
1367
+ <pre class="lines">
1368
+
1369
+
1370
+ 72
1371
+ 73
1372
+ 74
1373
+ 75
1374
+ 76
1375
+ 77
1376
+ 78
1377
+ 79</pre>
1378
+ </td>
1379
+ <td>
1380
+ <pre class="code"><span class="info file"># File 'lib/isimud/event.rb', line 72</span>
1381
+
1382
+ <span class='kw'>def</span> <span class='id identifier rubyid_as_json'>as_json</span><span class='lparen'>(</span><span class='id identifier rubyid_options'>options</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span>
1383
+ <span class='id identifier rubyid_session_id'>session_id</span> <span class='op'>=</span> <span class='id identifier rubyid_parameters'>parameters</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='symbol'>:session_id</span><span class='rparen'>)</span> <span class='op'>||</span> <span class='const'>Thread</span><span class='period'>.</span><span class='id identifier rubyid_current'>current</span><span class='lbracket'>[</span><span class='symbol'>:keas_session_id</span><span class='rbracket'>]</span>
1384
+
1385
+ <span class='id identifier rubyid_data'>data</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='label'>type:</span> <span class='id identifier rubyid_type'>type</span><span class='comma'>,</span> <span class='label'>action:</span> <span class='id identifier rubyid_action'>action</span><span class='comma'>,</span> <span class='label'>user_id:</span> <span class='id identifier rubyid_user_id'>user_id</span><span class='comma'>,</span> <span class='label'>occurred_at:</span> <span class='id identifier rubyid_occurred_at'>occurred_at</span><span class='comma'>,</span>
1386
+ <span class='label'>eventful_type:</span> <span class='id identifier rubyid_eventful_type'>eventful_type</span><span class='comma'>,</span> <span class='label'>eventful_id:</span> <span class='id identifier rubyid_eventful_id'>eventful_id</span><span class='comma'>,</span> <span class='label'>session_id:</span> <span class='id identifier rubyid_session_id'>session_id</span><span class='rbrace'>}</span>
1387
+ <span class='id identifier rubyid_data'>data</span><span class='lbracket'>[</span><span class='symbol'>:parameters</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_parameters'>parameters</span> <span class='kw'>unless</span> <span class='id identifier rubyid_options'>options</span><span class='lbracket'>[</span><span class='symbol'>:omit_parameters</span><span class='rbracket'>]</span>
1388
+ <span class='id identifier rubyid_data'>data</span>
1389
+ <span class='kw'>end</span></pre>
1390
+ </td>
1391
+ </tr>
1392
+ </table>
1393
+ </div>
1394
+
1395
+ <div class="method_details ">
1396
+ <h3 class="signature " id="publish-instance_method">
1397
+
1398
+ - (<tt>Object</tt>) <strong>publish</strong>
1399
+
1400
+
1401
+
1402
+
1403
+
1404
+ </h3><table class="source_code">
1405
+ <tr>
1406
+ <td>
1407
+ <pre class="lines">
1408
+
1409
+
1410
+ 97
1411
+ 98
1412
+ 99
1413
+ 100
1414
+ 101</pre>
1415
+ </td>
1416
+ <td>
1417
+ <pre class="code"><span class="info file"># File 'lib/isimud/event.rb', line 97</span>
1418
+
1419
+ <span class='kw'>def</span> <span class='id identifier rubyid_publish'>publish</span>
1420
+ <span class='id identifier rubyid_data'>data</span> <span class='op'>=</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_serialize'>serialize</span>
1421
+ <span class='id identifier rubyid_log'>log</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>Event#publish: </span><span class='embexpr_beg'>#{</span><span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_inspect'>inspect</span><span class='embexpr_end'>}</span><span class='tstring_end'>&quot;</span></span><span class='comma'>,</span> <span class='symbol'>:debug</span>
1422
+ <span class='const'>Isimud</span><span class='period'>.</span><span class='id identifier rubyid_client'>client</span><span class='period'>.</span><span class='id identifier rubyid_publish'>publish</span><span class='lparen'>(</span><span class='id identifier rubyid_exchange'>exchange</span><span class='comma'>,</span> <span class='id identifier rubyid_routing_key'>routing_key</span><span class='comma'>,</span> <span class='id identifier rubyid_data'>data</span><span class='rparen'>)</span>
1423
+ <span class='kw'>end</span></pre>
1424
+ </td>
1425
+ </tr>
1426
+ </table>
1427
+ </div>
1428
+
1429
+ <div class="method_details ">
1430
+ <h3 class="signature " id="routing_key-instance_method">
1431
+
1432
+ - (<tt>Object</tt>) <strong>routing_key</strong>
1433
+
1434
+
1435
+
1436
+
1437
+
1438
+ </h3><table class="source_code">
1439
+ <tr>
1440
+ <td>
1441
+ <pre class="lines">
1442
+
1443
+
1444
+ 65
1445
+ 66
1446
+ 67</pre>
1447
+ </td>
1448
+ <td>
1449
+ <pre class="code"><span class="info file"># File 'lib/isimud/event.rb', line 65</span>
1450
+
1451
+ <span class='kw'>def</span> <span class='id identifier rubyid_routing_key'>routing_key</span>
1452
+ <span class='lbracket'>[</span><span class='id identifier rubyid_type'>type</span><span class='period'>.</span><span class='id identifier rubyid_to_s'>to_s</span><span class='comma'>,</span> <span class='id identifier rubyid_eventful_type'>eventful_type</span><span class='comma'>,</span> <span class='id identifier rubyid_eventful_id'>eventful_id</span><span class='comma'>,</span> <span class='id identifier rubyid_action'>action</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id identifier rubyid_compact'>compact</span><span class='period'>.</span><span class='id identifier rubyid_join'>join</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>.</span><span class='tstring_end'>&#39;</span></span><span class='rparen'>)</span>
1453
+ <span class='kw'>end</span></pre>
1454
+ </td>
1455
+ </tr>
1456
+ </table>
1457
+ </div>
1458
+
1459
+ <div class="method_details ">
1460
+ <h3 class="signature " id="serialize-instance_method">
1461
+
1462
+ - (<tt>Object</tt>) <strong>serialize</strong>
1463
+
1464
+
1465
+
1466
+
1467
+
1468
+ </h3><table class="source_code">
1469
+ <tr>
1470
+ <td>
1471
+ <pre class="lines">
1472
+
1473
+
1474
+ 81
1475
+ 82
1476
+ 83</pre>
1477
+ </td>
1478
+ <td>
1479
+ <pre class="code"><span class="info file"># File 'lib/isimud/event.rb', line 81</span>
1480
+
1481
+ <span class='kw'>def</span> <span class='id identifier rubyid_serialize'>serialize</span>
1482
+ <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_to_json'>to_json</span>
1483
+ <span class='kw'>end</span></pre>
1484
+ </td>
1485
+ </tr>
1486
+ </table>
1487
+ </div>
1488
+
1489
+ </div>
1490
+
1491
+ </div>
1492
+
1493
+ <div id="footer">
1494
+ Generated on Fri Apr 3 09:28:08 2015 by
1495
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
1496
+ 0.8.7.6 (ruby-2.2.1).
1497
+ </div>
1498
+
1499
+ </body>
1500
+ </html>