zendesk_api 0.3.14 → 0.4.0.rc1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (141) hide show
  1. data/.yardopts +6 -2
  2. data/Gemfile +3 -2
  3. data/Gemfile.lock +4 -4
  4. data/Readme.md +3 -268
  5. data/lib/zendesk_api/actions.rb +51 -46
  6. data/lib/zendesk_api/association.rb +1 -1
  7. data/lib/zendesk_api/associations.rb +2 -6
  8. data/lib/zendesk_api/client.rb +8 -9
  9. data/lib/zendesk_api/collection.rb +84 -50
  10. data/lib/zendesk_api/configuration.rb +4 -0
  11. data/lib/zendesk_api/error.rb +22 -0
  12. data/lib/zendesk_api/middleware/request/etag_cache.rb +1 -7
  13. data/lib/zendesk_api/middleware/request/upload.rb +1 -2
  14. data/lib/zendesk_api/middleware/response/raise_error.rb +20 -0
  15. data/lib/zendesk_api/resource.rb +33 -5
  16. data/lib/zendesk_api/resources.rb +36 -11
  17. data/lib/zendesk_api/server/base.rb +1 -1
  18. data/lib/zendesk_api/server/helper.rb +3 -3
  19. data/lib/zendesk_api/server/models/zlib_json.rb +1 -1
  20. data/lib/zendesk_api/server/public/doc/ZendeskAPI.html +7 -7
  21. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Ability.html +415 -13
  22. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Activity.html +414 -51
  23. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Attachment.html +321 -25
  24. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Automation.html +413 -46
  25. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Bookmark.html +389 -26
  26. data/lib/zendesk_api/server/public/doc/ZendeskAPI/CRMData.html +415 -13
  27. data/lib/zendesk_api/server/public/doc/ZendeskAPI/CRMDataStatus.html +415 -13
  28. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Category.html +410 -47
  29. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Client.html +98 -362
  30. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Collection.html +457 -676
  31. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Configuration.html +110 -20
  32. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Create.html +264 -6
  33. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Create/ClassMethods.html +43 -82
  34. data/lib/zendesk_api/server/public/doc/ZendeskAPI/CreateResource.html +671 -15
  35. data/lib/zendesk_api/server/public/doc/ZendeskAPI/CustomRole.html +415 -13
  36. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Data.html +207 -233
  37. data/lib/zendesk_api/server/public/doc/ZendeskAPI/DataResource.html +499 -24
  38. data/lib/zendesk_api/server/public/doc/ZendeskAPI/DeleteResource.html +614 -15
  39. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Destroy.html +73 -23
  40. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Destroy/ClassMethod.html +68 -18
  41. data/lib/zendesk_api/server/public/doc/ZendeskAPI/{FormatError.html → Error.html} +19 -27
  42. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Error/ClientError.html +127 -0
  43. data/lib/zendesk_api/server/public/doc/ZendeskAPI/{Server/UserRequest.html → Error/NetworkError.html} +18 -16
  44. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Error/RecordInvalid.html +371 -0
  45. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Error/RecordNotFound.html +127 -0
  46. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Forum.html +426 -63
  47. data/lib/zendesk_api/server/public/doc/ZendeskAPI/ForumSubscription.html +414 -51
  48. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Group.html +389 -26
  49. data/lib/zendesk_api/server/public/doc/ZendeskAPI/GroupMembership.html +414 -51
  50. data/lib/zendesk_api/server/public/doc/ZendeskAPI/JobStatus.html +405 -16
  51. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Locale.html +405 -16
  52. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Macro.html +413 -46
  53. data/lib/zendesk_api/server/public/doc/ZendeskAPI/MobileDevice.html +404 -41
  54. data/lib/zendesk_api/server/public/doc/ZendeskAPI/OAuthClient.html +606 -0
  55. data/lib/zendesk_api/server/public/doc/ZendeskAPI/OAuthToken.html +810 -0
  56. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Organization.html +422 -59
  57. data/lib/zendesk_api/server/public/doc/ZendeskAPI/OrganizationField.html +606 -0
  58. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Read.html +75 -12
  59. data/lib/zendesk_api/server/public/doc/ZendeskAPI/ReadResource.html +593 -16
  60. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Request.html +418 -55
  61. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Request/Comment.html +420 -31
  62. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Resource.html +1025 -20
  63. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Role.html +415 -13
  64. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Rule.html +610 -0
  65. data/lib/zendesk_api/server/public/doc/ZendeskAPI/RuleExecution.html +317 -21
  66. data/lib/zendesk_api/server/public/doc/ZendeskAPI/SatisfactionRating.html +428 -39
  67. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Save.html +63 -79
  68. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Search.html +34 -26
  69. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Search/Result.html +305 -9
  70. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Setting.html +433 -41
  71. data/lib/zendesk_api/server/public/doc/ZendeskAPI/SharingAgreement.html +405 -16
  72. data/lib/zendesk_api/server/public/doc/ZendeskAPI/SingularResource.html +389 -26
  73. data/lib/zendesk_api/server/public/doc/ZendeskAPI/SuspendedTicket.html +600 -31
  74. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Ticket.html +464 -101
  75. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Ticket/Audit.html +427 -25
  76. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Ticket/Comment.html +435 -32
  77. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Ticket/Tag.html +389 -26
  78. data/lib/zendesk_api/server/public/doc/ZendeskAPI/TicketField.html +389 -26
  79. data/lib/zendesk_api/server/public/doc/ZendeskAPI/TicketMetric.html +592 -15
  80. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Topic.html +427 -64
  81. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Topic/TopicComment.html +907 -17
  82. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Topic/TopicVote.html +414 -55
  83. data/lib/zendesk_api/server/public/doc/ZendeskAPI/TopicComment.html +325 -29
  84. data/lib/zendesk_api/server/public/doc/ZendeskAPI/TopicSubscription.html +414 -51
  85. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Trigger.html +413 -46
  86. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Update.html +258 -6
  87. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Update/ClassMethod.html +62 -12
  88. data/lib/zendesk_api/server/public/doc/ZendeskAPI/UpdateResource.html +671 -15
  89. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Upload.html +800 -28
  90. data/lib/zendesk_api/server/public/doc/ZendeskAPI/User.html +505 -142
  91. data/lib/zendesk_api/server/public/doc/ZendeskAPI/User/Identity.html +412 -49
  92. data/lib/zendesk_api/server/public/doc/ZendeskAPI/User/TopicComment.html +475 -13
  93. data/lib/zendesk_api/server/public/doc/ZendeskAPI/UserField.html +606 -0
  94. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Verbs.html +9 -15
  95. data/lib/zendesk_api/server/public/doc/ZendeskAPI/View.html +433 -66
  96. data/lib/zendesk_api/server/public/doc/ZendeskAPI/ViewCount.html +415 -13
  97. data/lib/zendesk_api/server/public/doc/ZendeskAPI/ViewRow.html +451 -49
  98. data/lib/zendesk_api/server/public/doc/_index.html +72 -72
  99. data/lib/zendesk_api/server/public/doc/class_list.html +1 -1
  100. data/lib/zendesk_api/server/public/doc/css/style.css +10 -0
  101. data/lib/zendesk_api/server/public/doc/file.Readme.html +20 -260
  102. data/lib/zendesk_api/server/public/doc/file_list.html +1 -1
  103. data/lib/zendesk_api/server/public/doc/frames.html +1 -1
  104. data/lib/zendesk_api/server/public/doc/index.html +20 -260
  105. data/lib/zendesk_api/server/public/doc/method_list.html +309 -517
  106. data/lib/zendesk_api/server/public/doc/top-level-namespace.html +3 -35
  107. data/lib/zendesk_api/verbs.rb +0 -4
  108. data/lib/zendesk_api/version.rb +1 -1
  109. data/spec/core/client_spec.rb +53 -13
  110. data/spec/core/collection_spec.rb +32 -4
  111. data/spec/core/create_resource_spec.rb +1 -1
  112. data/spec/core/data_resource_spec.rb +2 -2
  113. data/spec/core/middleware/request/etag_cache_spec.rb +6 -7
  114. data/spec/core/middleware/request/upload_spec.rb +2 -10
  115. data/spec/core/middleware/response/callback_spec.rb +1 -1
  116. data/spec/core/middleware/response/raise_error_spec.rb +40 -0
  117. data/spec/core/read_resource_spec.rb +0 -2
  118. data/spec/core/resource_spec.rb +13 -5
  119. data/spec/core/search_spec.rb +1 -1
  120. data/spec/core/spec_helper.rb +3 -3
  121. data/spec/live/automation_spec.rb +23 -0
  122. data/spec/live/organization_field_spec.rb +12 -0
  123. data/spec/live/ticket_spec.rb +8 -2
  124. data/spec/live/trigger_spec.rb +23 -0
  125. data/spec/live/user_field_spec.rb +12 -0
  126. data/spec/live/user_spec.rb +0 -2
  127. data/spec/live/view_spec.rb +17 -1
  128. data/spec/server/spec_helper.rb +2 -2
  129. data/zendesk_api.gemspec +1 -1
  130. metadata +88 -51
  131. checksums.yaml +0 -7
  132. data/lib/zendesk_api/rescue.rb +0 -63
  133. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Console.html +0 -860
  134. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Console/Eval.html +0 -190
  135. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Server.html +0 -131
  136. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Server/App.html +0 -523
  137. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Server/Helper.html +0 -684
  138. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Server/HtmlRenderer.html +0 -303
  139. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Server/HtmlRenderer/RedcarpetRenderer.html +0 -508
  140. data/lib/zendesk_api/server/public/doc/ZendeskAPI/Server/ZlibJSON.html +0 -244
  141. data/spec/core/rescue_spec.rb +0 -151
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Class: ZendeskAPI::Collection
8
8
 
9
- &mdash; Documentation by YARD 0.8.4.1
9
+ &mdash; Documentation by YARD 0.8.5.2
10
10
 
11
11
  </title>
12
12
 
@@ -94,9 +94,7 @@
94
94
 
95
95
 
96
96
  <dt class="r2 last">Defined in:</dt>
97
- <dd class="r2 last">lib/zendesk_api/collection.rb<span class="defines">,<br />
98
- lib/zendesk_api/console/extensions.rb</span>
99
- </dd>
97
+ <dd class="r2 last">lib/zendesk_api/collection.rb</dd>
100
98
 
101
99
  </dl>
102
100
  <div class="clear"></div>
@@ -247,7 +245,7 @@ comma-separated list.</p>
247
245
  <li class="public ">
248
246
  <span class="summary_signature">
249
247
 
250
- <a href="#%2F-instance_method" title="#/ (instance method)">- (Object) <strong>/</strong>(id) </a>
248
+ <a href="#%3C%3C-instance_method" title="#&lt;&lt; (instance method)">- (Object) <strong>&lt;&lt;</strong>(item) </a>
251
249
 
252
250
 
253
251
 
@@ -261,7 +259,9 @@ comma-separated list.</p>
261
259
 
262
260
 
263
261
 
264
- <span class="summary_desc"><div class='inline'></div></span>
262
+ <span class="summary_desc"><div class='inline'>
263
+ <p>Adds an item to this collection.</p>
264
+ </div></span>
265
265
 
266
266
  </li>
267
267
 
@@ -269,7 +269,7 @@ comma-separated list.</p>
269
269
  <li class="public ">
270
270
  <span class="summary_signature">
271
271
 
272
- <a href="#%3C%3C-instance_method" title="#&lt;&lt; (instance method)">- (Object) <strong>&lt;&lt;</strong>(item) </a>
272
+ <a href="#all-instance_method" title="#all (instance method)">- (Object) <strong>all</strong>(start_page = @options[&quot;page&quot;], &amp;block) </a>
273
273
 
274
274
 
275
275
 
@@ -284,7 +284,7 @@ comma-separated list.</p>
284
284
 
285
285
 
286
286
  <span class="summary_desc"><div class='inline'>
287
- <p>Adds an item to this collection.</p>
287
+ <p>Calls #each on every page with the passed in block.</p>
288
288
  </div></span>
289
289
 
290
290
  </li>
@@ -293,7 +293,7 @@ comma-separated list.</p>
293
293
  <li class="public ">
294
294
  <span class="summary_signature">
295
295
 
296
- <a href="#clear_cache-instance_method" title="#clear_cache (instance method)">- (Object) <strong>clear_cache</strong> </a>
296
+ <a href="#all%21-instance_method" title="#all! (instance method)">- (Object) <strong>all!</strong>(start_page = @options[&quot;page&quot;], &amp;block) </a>
297
297
 
298
298
 
299
299
 
@@ -308,7 +308,7 @@ comma-separated list.</p>
308
308
 
309
309
 
310
310
  <span class="summary_desc"><div class='inline'>
311
- <p>Clears all cached resources and associated values.</p>
311
+ <p>Calls #each on every page with the passed in block.</p>
312
312
  </div></span>
313
313
 
314
314
  </li>
@@ -317,7 +317,7 @@ comma-separated list.</p>
317
317
  <li class="public ">
318
318
  <span class="summary_signature">
319
319
 
320
- <a href="#count-instance_method" title="#count (instance method)">- (Number) <strong>count</strong> </a>
320
+ <a href="#clear_cache-instance_method" title="#clear_cache (instance method)">- (Object) <strong>clear_cache</strong> </a>
321
321
 
322
322
 
323
323
 
@@ -332,7 +332,7 @@ comma-separated list.</p>
332
332
 
333
333
 
334
334
  <span class="summary_desc"><div class='inline'>
335
- <p>The total number of resources server-side (disregarding pagination).</p>
335
+ <p>Clears all cached resources and associated values.</p>
336
336
  </div></span>
337
337
 
338
338
  </li>
@@ -341,7 +341,7 @@ comma-separated list.</p>
341
341
  <li class="public ">
342
342
  <span class="summary_signature">
343
343
 
344
- <a href="#create-instance_method" title="#create (instance method)">- (Object) <strong>create</strong>(attributes = {}) </a>
344
+ <a href="#count-instance_method" title="#count (instance method)">- (Number) <strong>count</strong> </a>
345
345
 
346
346
 
347
347
 
@@ -356,7 +356,7 @@ comma-separated list.</p>
356
356
 
357
357
 
358
358
  <span class="summary_desc"><div class='inline'>
359
- <p>Passes arguments and the proper path to the resource class method.</p>
359
+ <p>The total number of resources server-side (disregarding pagination).</p>
360
360
  </div></span>
361
361
 
362
362
  </li>
@@ -365,7 +365,7 @@ comma-separated list.</p>
365
365
  <li class="public ">
366
366
  <span class="summary_signature">
367
367
 
368
- <a href="#destroy-instance_method" title="#destroy (instance method)">- (Object) <strong>destroy</strong>(opts = {}) </a>
368
+ <a href="#count%21-instance_method" title="#count! (instance method)">- (Number) <strong>count!</strong> </a>
369
369
 
370
370
 
371
371
 
@@ -379,7 +379,9 @@ comma-separated list.</p>
379
379
 
380
380
 
381
381
 
382
- <span class="summary_desc"><div class='inline'></div></span>
382
+ <span class="summary_desc"><div class='inline'>
383
+ <p>The total number of resources server-side (disregarding pagination).</p>
384
+ </div></span>
383
385
 
384
386
  </li>
385
387
 
@@ -387,7 +389,7 @@ comma-separated list.</p>
387
389
  <li class="public ">
388
390
  <span class="summary_signature">
389
391
 
390
- <a href="#each_page-instance_method" title="#each_page (instance method)">- (Object) <strong>each_page</strong>(&amp;block) </a>
392
+ <a href="#each_page-instance_method" title="#each_page (instance method)">- (Object) <strong>each_page</strong>(*args, &amp;block) </a>
391
393
 
392
394
 
393
395
 
@@ -401,9 +403,7 @@ comma-separated list.</p>
401
403
 
402
404
 
403
405
 
404
- <span class="summary_desc"><div class='inline'>
405
- <p>Calls #each on every page with the passed in block.</p>
406
- </div></span>
406
+ <span class="summary_desc"><div class='inline'></div></span>
407
407
 
408
408
  </li>
409
409
 
@@ -411,7 +411,7 @@ comma-separated list.</p>
411
411
  <li class="public ">
412
412
  <span class="summary_signature">
413
413
 
414
- <a href="#fetch-instance_method" title="#fetch (instance method)">- (Object) <strong>fetch</strong>(reload = false) </a>
414
+ <a href="#each_page%21-instance_method" title="#each_page! (instance method)">- (Object) <strong>each_page!</strong>(*args, &amp;block) </a>
415
415
 
416
416
 
417
417
 
@@ -425,9 +425,7 @@ comma-separated list.</p>
425
425
 
426
426
 
427
427
 
428
- <span class="summary_desc"><div class='inline'>
429
- <p>Executes actual GET from API and loads resources into proper class.</p>
430
- </div></span>
428
+ <span class="summary_desc"><div class='inline'></div></span>
431
429
 
432
430
  </li>
433
431
 
@@ -435,7 +433,7 @@ comma-separated list.</p>
435
433
  <li class="public ">
436
434
  <span class="summary_signature">
437
435
 
438
- <a href="#find-instance_method" title="#find (instance method)">- (Object) <strong>find</strong>(opts = {}) </a>
436
+ <a href="#fetch-instance_method" title="#fetch (instance method)">- (Object) <strong>fetch</strong>(*args) </a>
439
437
 
440
438
 
441
439
 
@@ -457,7 +455,7 @@ comma-separated list.</p>
457
455
  <li class="public ">
458
456
  <span class="summary_signature">
459
457
 
460
- <a href="#first_page%3F-instance_method" title="#first_page? (instance method)">- (Boolean) <strong>first_page?</strong> </a>
458
+ <a href="#fetch%21-instance_method" title="#fetch! (instance method)">- (Object) <strong>fetch!</strong>(reload = false) </a>
461
459
 
462
460
 
463
461
 
@@ -471,7 +469,9 @@ comma-separated list.</p>
471
469
 
472
470
 
473
471
 
474
- <span class="summary_desc"><div class='inline'></div></span>
472
+ <span class="summary_desc"><div class='inline'>
473
+ <p>Executes actual GET from API and loads resources into proper class.</p>
474
+ </div></span>
475
475
 
476
476
  </li>
477
477
 
@@ -479,7 +479,7 @@ comma-separated list.</p>
479
479
  <li class="public ">
480
480
  <span class="summary_signature">
481
481
 
482
- <a href="#format_headers-instance_method" title="#format_headers (instance method)">- (Object) <strong>format_headers</strong> </a>
482
+ <a href="#first_page%3F-instance_method" title="#first_page? (instance method)">- (Boolean) <strong>first_page?</strong> </a>
483
483
 
484
484
 
485
485
 
@@ -565,50 +565,6 @@ comma-separated list.</p>
565
565
 
566
566
 
567
567
 
568
- <span class="summary_desc"><div class='inline'></div></span>
569
-
570
- </li>
571
-
572
-
573
- <li class="public ">
574
- <span class="summary_signature">
575
-
576
- <a href="#loaded%3F-instance_method" title="#loaded? (instance method)">- (Boolean) <strong>loaded?</strong> </a>
577
-
578
-
579
-
580
- </span>
581
-
582
-
583
-
584
-
585
-
586
-
587
-
588
-
589
-
590
- <span class="summary_desc"><div class='inline'></div></span>
591
-
592
- </li>
593
-
594
-
595
- <li class="public ">
596
- <span class="summary_signature">
597
-
598
- <a href="#log_error-instance_method" title="#log_error (instance method)">- (Object) <strong>log_error</strong>(e, _) </a>
599
-
600
-
601
-
602
- </span>
603
-
604
-
605
-
606
-
607
-
608
-
609
-
610
-
611
-
612
568
  <span class="summary_desc"><div class='inline'></div></span>
613
569
 
614
570
  </li>
@@ -665,7 +621,7 @@ comma-separated list.</p>
665
621
  <li class="public ">
666
622
  <span class="summary_signature">
667
623
 
668
- <a href="#orig_log_error-instance_method" title="#orig_log_error (instance method)">- (Object) <strong>orig_log_error</strong> </a>
624
+ <a href="#page-instance_method" title="#page (instance method)">- (Collection) <strong>page</strong>(number) </a>
669
625
 
670
626
 
671
627
 
@@ -679,7 +635,9 @@ comma-separated list.</p>
679
635
 
680
636
 
681
637
 
682
- <span class="summary_desc"><div class='inline'></div></span>
638
+ <span class="summary_desc"><div class='inline'>
639
+ <p>Changes the page option.</p>
640
+ </div></span>
683
641
 
684
642
  </li>
685
643
 
@@ -687,7 +645,7 @@ comma-separated list.</p>
687
645
  <li class="public ">
688
646
  <span class="summary_signature">
689
647
 
690
- <a href="#page-instance_method" title="#page (instance method)">- (Collection) <strong>page</strong>(number) </a>
648
+ <a href="#path-instance_method" title="#path (instance method)">- (Object) <strong>path</strong> </a>
691
649
 
692
650
 
693
651
 
@@ -702,7 +660,7 @@ comma-separated list.</p>
702
660
 
703
661
 
704
662
  <span class="summary_desc"><div class='inline'>
705
- <p>Changes the page option.</p>
663
+ <p>The API path to this collection.</p>
706
664
  </div></span>
707
665
 
708
666
  </li>
@@ -711,7 +669,7 @@ comma-separated list.</p>
711
669
  <li class="public ">
712
670
  <span class="summary_signature">
713
671
 
714
- <a href="#path-instance_method" title="#path (instance method)">- (Object) <strong>path</strong> </a>
672
+ <a href="#per_page-instance_method" title="#per_page (instance method)">- (Collection) <strong>per_page</strong>(count) </a>
715
673
 
716
674
 
717
675
 
@@ -726,7 +684,7 @@ comma-separated list.</p>
726
684
 
727
685
 
728
686
  <span class="summary_desc"><div class='inline'>
729
- <p>The API path to this collection.</p>
687
+ <p>Changes the per_page option.</p>
730
688
  </div></span>
731
689
 
732
690
  </li>
@@ -735,7 +693,7 @@ comma-separated list.</p>
735
693
  <li class="public ">
736
694
  <span class="summary_signature">
737
695
 
738
- <a href="#per_page-instance_method" title="#per_page (instance method)">- (Collection) <strong>per_page</strong>(count) </a>
696
+ <a href="#prev-instance_method" title="#prev (instance method)">- (Object) <strong>prev</strong> </a>
739
697
 
740
698
 
741
699
 
@@ -750,7 +708,7 @@ comma-separated list.</p>
750
708
 
751
709
 
752
710
  <span class="summary_desc"><div class='inline'>
753
- <p>Changes the per_page option.</p>
711
+ <p>Find the previous page.</p>
754
712
  </div></span>
755
713
 
756
714
  </li>
@@ -759,7 +717,7 @@ comma-separated list.</p>
759
717
  <li class="public ">
760
718
  <span class="summary_signature">
761
719
 
762
- <a href="#prev-instance_method" title="#prev (instance method)">- (Object) <strong>prev</strong> </a>
720
+ <a href="#replace-instance_method" title="#replace (instance method)">- (Object) <strong>replace</strong>(collection) </a>
763
721
 
764
722
 
765
723
 
@@ -774,7 +732,8 @@ comma-separated list.</p>
774
732
 
775
733
 
776
734
  <span class="summary_desc"><div class='inline'>
777
- <p>Find the previous page.</p>
735
+ <p>Replaces the current (loaded or not) resources with the passed in
736
+ collection.</p>
778
737
  </div></span>
779
738
 
780
739
  </li>
@@ -783,7 +742,7 @@ comma-separated list.</p>
783
742
  <li class="public ">
784
743
  <span class="summary_signature">
785
744
 
786
- <a href="#replace-instance_method" title="#replace (instance method)">- (Object) <strong>replace</strong>(collection) </a>
745
+ <a href="#save-instance_method" title="#save (instance method)">- (Collection) <strong>save</strong> </a>
787
746
 
788
747
 
789
748
 
@@ -798,8 +757,7 @@ comma-separated list.</p>
798
757
 
799
758
 
800
759
  <span class="summary_desc"><div class='inline'>
801
- <p>Replaces the current (loaded or not) resources with the passed in
802
- collection.</p>
760
+ <p>Saves all newly created resources stored in this collection.</p>
803
761
  </div></span>
804
762
 
805
763
  </li>
@@ -808,7 +766,7 @@ collection.</p>
808
766
  <li class="public ">
809
767
  <span class="summary_signature">
810
768
 
811
- <a href="#save-instance_method" title="#save (instance method)">- (Collection) <strong>save</strong> </a>
769
+ <a href="#save%21-instance_method" title="#save! (instance method)">- (Collection) <strong>save!</strong> </a>
812
770
 
813
771
 
814
772
 
@@ -856,7 +814,7 @@ collection.</p>
856
814
  <li class="public ">
857
815
  <span class="summary_signature">
858
816
 
859
- <a href="#update-instance_method" title="#update (instance method)">- (Object) <strong>update</strong>(opts = {}) </a>
817
+ <a href="#to_a%21-instance_method" title="#to_a! (instance method)">- (Object) <strong>to_a!</strong> </a>
860
818
 
861
819
 
862
820
 
@@ -870,7 +828,9 @@ collection.</p>
870
828
 
871
829
 
872
830
 
873
- <span class="summary_desc"><div class='inline'></div></span>
831
+ <span class="summary_desc"><div class='inline'>
832
+ <p>Alias for fetch!(false).</p>
833
+ </div></span>
874
834
 
875
835
  </li>
876
836
 
@@ -880,16 +840,6 @@ collection.</p>
880
840
 
881
841
 
882
842
 
883
-
884
-
885
-
886
-
887
-
888
-
889
-
890
-
891
-
892
-
893
843
  <div id="constructor_details" class="method_details_list">
894
844
  <h2>Constructor Details</h2>
895
845
 
@@ -975,6 +925,8 @@ per_page.</p>
975
925
  <pre class="lines">
976
926
 
977
927
 
928
+ 27
929
+ 28
978
930
  29
979
931
  30
980
932
  31
@@ -990,51 +942,27 @@ per_page.</p>
990
942
  41
991
943
  42
992
944
  43
993
- 44
994
- 45
995
- 46
996
- 47
997
- 48
998
- 49
999
- 50
1000
- 51
1001
- 52
1002
- 53
1003
- 54
1004
- 55
1005
- 56
1006
- 57</pre>
945
+ 44</pre>
1007
946
  </td>
1008
947
  <td>
1009
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 29</span>
948
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 27</span>
1010
949
 
1011
950
  <span class='kw'>def</span> <span class='id identifier rubyid_initialize'>initialize</span><span class='lparen'>(</span><span class='id identifier rubyid_client'>client</span><span class='comma'>,</span> <span class='id identifier rubyid_resource'>resource</span><span class='comma'>,</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>
1012
- <span class='ivar'>@client</span><span class='comma'>,</span> <span class='ivar'>@resource</span> <span class='op'>=</span> <span class='id identifier rubyid_client'>client</span><span class='comma'>,</span> <span class='id identifier rubyid_resource'>resource</span><span class='period'>.</span><span class='id identifier rubyid_resource_name'>resource_name</span>
951
+ <span class='ivar'>@client</span><span class='comma'>,</span> <span class='ivar'>@resource_class</span><span class='comma'>,</span> <span class='ivar'>@resource</span> <span class='op'>=</span> <span class='id identifier rubyid_client'>client</span><span class='comma'>,</span> <span class='id identifier rubyid_resource'>resource</span><span class='comma'>,</span> <span class='id identifier rubyid_resource'>resource</span><span class='period'>.</span><span class='id identifier rubyid_resource_name'>resource_name</span>
1013
952
  <span class='ivar'>@options</span> <span class='op'>=</span> <span class='const'>Hashie</span><span class='op'>::</span><span class='const'>Mash</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='id identifier rubyid_options'>options</span><span class='rparen'>)</span>
1014
953
 
1015
- <span class='ivar'>@verb</span> <span class='op'>=</span> <span class='ivar'>@options</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='symbol'>:verb</span><span class='rparen'>)</span>
1016
- <span class='ivar'>@collection_path</span> <span class='op'>=</span> <span class='ivar'>@options</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='symbol'>:collection_path</span><span class='rparen'>)</span>
1017
-
1018
- <span class='id identifier rubyid_association_options'>association_options</span> <span class='op'>=</span> <span class='lbrace'>{</span> <span class='symbol'>:path</span> <span class='op'>=&gt;</span> <span class='ivar'>@options</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='symbol'>:path</span><span class='rparen'>)</span> <span class='rbrace'>}</span>
1019
- <span class='id identifier rubyid_association_options'>association_options</span><span class='lbracket'>[</span><span class='symbol'>:path</span><span class='rbracket'>]</span> <span class='op'>||=</span> <span class='ivar'>@collection_path</span><span class='period'>.</span><span class='id identifier rubyid_join'>join</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>/</span><span class='tstring_end'>&quot;</span></span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='ivar'>@collection_path</span>
1020
- <span class='ivar'>@association</span> <span class='op'>=</span> <span class='ivar'>@options</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='symbol'>:association</span><span class='rparen'>)</span> <span class='op'>||</span> <span class='const'>Association</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='id identifier rubyid_association_options'>association_options</span><span class='period'>.</span><span class='id identifier rubyid_merge'>merge</span><span class='lparen'>(</span><span class='symbol'>:class</span> <span class='op'>=&gt;</span> <span class='id identifier rubyid_resource'>resource</span><span class='rparen'>)</span><span class='rparen'>)</span>
954
+ <span class='id identifier rubyid_set_association_from_options'>set_association_from_options</span>
955
+ <span class='id identifier rubyid_join_special_params'>join_special_params</span>
1021
956
 
1022
- <span class='comment'># some params use comma-joined strings instead of query-based arrays for multiple values
1023
- </span> <span class='ivar'>@options</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_k'>k</span><span class='comma'>,</span> <span class='id identifier rubyid_v'>v</span><span class='op'>|</span>
1024
- <span class='kw'>if</span> <span class='const'>SPECIALLY_JOINED_PARAMS</span><span class='period'>.</span><span class='id identifier rubyid_include?'>include?</span><span class='lparen'>(</span><span class='id identifier rubyid_k'>k</span><span class='period'>.</span><span class='id identifier rubyid_to_sym'>to_sym</span><span class='rparen'>)</span> <span class='op'>&amp;&amp;</span> <span class='id identifier rubyid_v'>v</span><span class='period'>.</span><span class='id identifier rubyid_is_a?'>is_a?</span><span class='lparen'>(</span><span class='const'>Array</span><span class='rparen'>)</span>
1025
- <span class='ivar'>@options</span><span class='lbracket'>[</span><span class='id identifier rubyid_k'>k</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_v'>v</span><span class='period'>.</span><span class='id identifier rubyid_join'>join</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>,</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span>
1026
- <span class='kw'>end</span>
1027
- <span class='kw'>end</span>
1028
-
1029
- <span class='ivar'>@collection_path</span> <span class='op'>||=</span> <span class='lbracket'>[</span><span class='ivar'>@resource</span><span class='rbracket'>]</span>
1030
- <span class='ivar'>@resource_class</span> <span class='op'>=</span> <span class='id identifier rubyid_resource'>resource</span>
1031
- <span class='ivar'>@fetchable</span> <span class='op'>=</span> <span class='kw'>true</span>
957
+ <span class='ivar'>@verb</span> <span class='op'>=</span> <span class='ivar'>@options</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='symbol'>:verb</span><span class='rparen'>)</span>
1032
958
  <span class='ivar'>@includes</span> <span class='op'>=</span> <span class='const'>Array</span><span class='lparen'>(</span><span class='ivar'>@options</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='symbol'>:include</span><span class='rparen'>)</span><span class='rparen'>)</span>
1033
959
 
1034
960
  <span class='comment'># Used for Attachments, TicketComment
1035
961
  </span> <span class='kw'>if</span> <span class='ivar'>@resource_class</span><span class='period'>.</span><span class='id identifier rubyid_is_a?'>is_a?</span><span class='lparen'>(</span><span class='const'>Class</span><span class='rparen'>)</span> <span class='op'>&amp;&amp;</span> <span class='ivar'>@resource_class</span><span class='period'>.</span><span class='id identifier rubyid_superclass'>superclass</span> <span class='op'>==</span> <span class='const'>ZendeskAPI</span><span class='op'>::</span><span class='const'>Data</span>
1036
962
  <span class='ivar'>@resources</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span>
1037
963
  <span class='ivar'>@fetchable</span> <span class='op'>=</span> <span class='kw'>false</span>
964
+ <span class='kw'>else</span>
965
+ <span class='ivar'>@fetchable</span> <span class='op'>=</span> <span class='kw'>true</span>
1038
966
  <span class='kw'>end</span>
1039
967
  <span class='kw'>end</span></pre>
1040
968
  </td>
@@ -1076,34 +1004,26 @@ per_page.</p>
1076
1004
  <pre class="lines">
1077
1005
 
1078
1006
 
1079
- 279
1080
- 280
1081
- 281
1082
- 282
1083
- 283
1084
- 284
1085
- 285
1086
- 286
1087
- 287
1088
- 288
1089
- 289
1090
- 290
1091
- 291</pre>
1007
+ 245
1008
+ 246
1009
+ 247
1010
+ 248
1011
+ 249
1012
+ 250
1013
+ 251
1014
+ 252
1015
+ 253</pre>
1092
1016
  </td>
1093
1017
  <td>
1094
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 279</span>
1018
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 245</span>
1095
1019
 
1096
1020
  <span class='kw'>def</span> <span class='id identifier rubyid_method_missing'>method_missing</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='comma'>,</span> <span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1097
- <span class='id identifier rubyid_methods'>methods</span> <span class='op'>=</span> <span class='ivar'>@resource_class</span><span class='period'>.</span><span class='id identifier rubyid_singleton_methods'>singleton_methods</span><span class='lparen'>(</span><span class='kw'>false</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_map'>map</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='symbol'>:to_sym</span><span class='rparen'>)</span>
1098
-
1099
- <span class='kw'>if</span> <span class='id identifier rubyid_methods'>methods</span><span class='period'>.</span><span class='id identifier rubyid_include?'>include?</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='rparen'>)</span>
1100
- <span class='ivar'>@resource_class</span><span class='period'>.</span><span class='id identifier rubyid_send'>send</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='comma'>,</span> <span class='ivar'>@client</span><span class='comma'>,</span> <span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1021
+ <span class='kw'>if</span> <span class='id identifier rubyid_resource_methods'>resource_methods</span><span class='period'>.</span><span class='id identifier rubyid_include?'>include?</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='rparen'>)</span>
1022
+ <span class='id identifier rubyid_collection_method'>collection_method</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='comma'>,</span> <span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1101
1023
  <span class='kw'>elsif</span> <span class='const'>Array</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='period'>.</span><span class='id identifier rubyid_respond_to?'>respond_to?</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='rparen'>)</span>
1102
- <span class='id identifier rubyid_to_a'>to_a</span><span class='period'>.</span><span class='id identifier rubyid_send'>send</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='comma'>,</span> <span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1024
+ <span class='id identifier rubyid_array_method'>array_method</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='comma'>,</span> <span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1103
1025
  <span class='kw'>else</span>
1104
- <span class='id identifier rubyid_opts'>opts</span> <span class='op'>=</span> <span class='id identifier rubyid_args'>args</span><span class='period'>.</span><span class='id identifier rubyid_last'>last</span><span class='period'>.</span><span class='id identifier rubyid_is_a?'>is_a?</span><span class='lparen'>(</span><span class='const'>Hash</span><span class='rparen'>)</span> <span class='op'>?</span> <span class='id identifier rubyid_args'>args</span><span class='period'>.</span><span class='id identifier rubyid_last'>last</span> <span class='op'>:</span> <span class='lbrace'>{</span><span class='rbrace'>}</span>
1105
- <span class='id identifier rubyid_opts'>opts</span><span class='period'>.</span><span class='id identifier rubyid_merge!'>merge!</span><span class='lparen'>(</span><span class='symbol'>:collection_path</span> <span class='op'>=&gt;</span> <span class='ivar'>@collection_path</span><span class='period'>.</span><span class='id identifier rubyid_dup'>dup</span><span class='period'>.</span><span class='id identifier rubyid_push'>push</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='rparen'>)</span><span class='rparen'>)</span>
1106
- <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_class'>class</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='ivar'>@client</span><span class='comma'>,</span> <span class='ivar'>@resource_class</span><span class='comma'>,</span> <span class='ivar'>@options</span><span class='period'>.</span><span class='id identifier rubyid_merge'>merge</span><span class='lparen'>(</span><span class='id identifier rubyid_opts'>opts</span><span class='rparen'>)</span><span class='rparen'>)</span>
1026
+ <span class='id identifier rubyid_next_collection'>next_collection</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='comma'>,</span> <span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1107
1027
  <span class='kw'>end</span>
1108
1028
  <span class='kw'>end</span></pre>
1109
1029
  </td>
@@ -1162,12 +1082,12 @@ per_page.</p>
1162
1082
  <pre class="lines">
1163
1083
 
1164
1084
 
1165
- 16
1166
- 17
1167
- 18</pre>
1085
+ 14
1086
+ 15
1087
+ 16</pre>
1168
1088
  </td>
1169
1089
  <td>
1170
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 16</span>
1090
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 14</span>
1171
1091
 
1172
1092
  <span class='kw'>def</span> <span class='id identifier rubyid_association'>association</span>
1173
1093
  <span class='ivar'>@association</span>
@@ -1223,12 +1143,12 @@ per_page.</p>
1223
1143
  <pre class="lines">
1224
1144
 
1225
1145
 
1226
- 22
1227
- 23
1228
- 24</pre>
1146
+ 20
1147
+ 21
1148
+ 22</pre>
1229
1149
  </td>
1230
1150
  <td>
1231
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 22</span>
1151
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 20</span>
1232
1152
 
1233
1153
  <span class='kw'>def</span> <span class='id identifier rubyid_options'>options</span>
1234
1154
  <span class='ivar'>@options</span>
@@ -1284,12 +1204,12 @@ per_page.</p>
1284
1204
  <pre class="lines">
1285
1205
 
1286
1206
 
1287
- 19
1288
- 20
1289
- 21</pre>
1207
+ 17
1208
+ 18
1209
+ 19</pre>
1290
1210
  </td>
1291
1211
  <td>
1292
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 19</span>
1212
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 17</span>
1293
1213
 
1294
1214
  <span class='kw'>def</span> <span class='id identifier rubyid_response'>response</span>
1295
1215
  <span class='ivar'>@response</span>
@@ -1307,67 +1227,7 @@ per_page.</p>
1307
1227
 
1308
1228
 
1309
1229
  <div class="method_details first">
1310
- <h3 class="signature first" id="/-instance_method">
1311
-
1312
- - (<tt>Object</tt>) <strong>/</strong>(id)
1313
-
1314
-
1315
-
1316
-
1317
-
1318
- </h3><table class="source_code">
1319
- <tr>
1320
- <td>
1321
- <pre class="lines">
1322
-
1323
-
1324
- 4
1325
- 5
1326
- 6
1327
- 7
1328
- 8
1329
- 9
1330
- 10
1331
- 11
1332
- 12
1333
- 13
1334
- 14
1335
- 15
1336
- 16
1337
- 17
1338
- 18
1339
- 19
1340
- 20
1341
- 21</pre>
1342
- </td>
1343
- <td>
1344
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/console/extensions.rb', line 4</span>
1345
-
1346
- <span class='kw'>def</span> <span class='op'>/</span><span class='lparen'>(</span><span class='id identifier rubyid_id'>id</span><span class='rparen'>)</span>
1347
- <span class='kw'>if</span> <span class='id identifier rubyid_id'>id</span> <span class='op'>==</span> <span class='const'>ZendeskAPI</span><span class='op'>::</span><span class='const'>Console</span><span class='op'>::</span><span class='const'>ZD_DIRUP</span>
1348
- <span class='kw'>if</span> <span class='ivar'>@collection_path</span><span class='period'>.</span><span class='id identifier rubyid_length'>length</span> <span class='op'>==</span> <span class='int'>1</span>
1349
- <span class='ivar'>@client</span>
1350
- <span class='kw'>else</span>
1351
- <span class='ivar'>@collection_path</span><span class='period'>.</span><span class='id identifier rubyid_shift'>shift</span>
1352
- <span class='kw'>self</span>
1353
- <span class='kw'>end</span>
1354
- <span class='kw'>elsif</span> <span class='id identifier rubyid_id'>id</span><span class='period'>.</span><span class='id identifier rubyid_is_a?'>is_a?</span><span class='lparen'>(</span><span class='const'>Fixnum</span><span class='rparen'>)</span>
1355
- <span class='kw'>if</span> <span class='id identifier rubyid_loaded?'>loaded?</span>
1356
- <span class='id identifier rubyid_detect'>detect</span> <span class='lbrace'>{</span><span class='op'>|</span><span class='id identifier rubyid_obj'>obj</span><span class='op'>|</span> <span class='id identifier rubyid_obj'>obj</span><span class='period'>.</span><span class='id identifier rubyid_id'>id</span> <span class='op'>==</span> <span class='id identifier rubyid_id'>id</span><span class='rbrace'>}</span>
1357
- <span class='kw'>else</span>
1358
- <span class='id identifier rubyid_find'>find</span><span class='lparen'>(</span><span class='symbol'>:id</span> <span class='op'>=&gt;</span> <span class='id identifier rubyid_id'>id</span><span class='rparen'>)</span>
1359
- <span class='kw'>end</span>
1360
- <span class='kw'>elsif</span> <span class='op'>!</span><span class='id identifier rubyid_id'>id</span><span class='period'>.</span><span class='id identifier rubyid_is_a?'>is_a?</span><span class='lparen'>(</span><span class='const'>ZendeskAPI</span><span class='op'>::</span><span class='const'>Collection</span><span class='rparen'>)</span>
1361
- <span class='id identifier rubyid_send'>send</span><span class='lparen'>(</span><span class='id identifier rubyid_id'>id</span><span class='rparen'>)</span>
1362
- <span class='kw'>end</span>
1363
- <span class='kw'>end</span></pre>
1364
- </td>
1365
- </tr>
1366
- </table>
1367
- </div>
1368
-
1369
- <div class="method_details ">
1370
- <h3 class="signature " id="<<-instance_method">
1230
+ <h3 class="signature first" id="<<-instance_method">
1371
1231
 
1372
1232
  - (<tt>Object</tt>) <strong>&lt;&lt;</strong>(item)
1373
1233
 
@@ -1452,22 +1312,22 @@ per_page.</p>
1452
1312
  <pre class="lines">
1453
1313
 
1454
1314
 
1455
- 139
1456
- 140
1457
- 141
1458
- 142
1459
- 143
1460
- 144
1461
- 145
1462
- 146
1463
- 147
1464
- 148
1465
- 149
1466
- 150
1467
- 151</pre>
1315
+ 120
1316
+ 121
1317
+ 122
1318
+ 123
1319
+ 124
1320
+ 125
1321
+ 126
1322
+ 127
1323
+ 128
1324
+ 129
1325
+ 130
1326
+ 131
1327
+ 132</pre>
1468
1328
  </td>
1469
1329
  <td>
1470
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 139</span>
1330
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 120</span>
1471
1331
 
1472
1332
  <span class='kw'>def</span> <span class='op'>&lt;&lt;</span><span class='lparen'>(</span><span class='id identifier rubyid_item'>item</span><span class='rparen'>)</span>
1473
1333
  <span class='id identifier rubyid_fetch'>fetch</span>
@@ -1488,9 +1348,9 @@ per_page.</p>
1488
1348
  </div>
1489
1349
 
1490
1350
  <div class="method_details ">
1491
- <h3 class="signature " id="clear_cache-instance_method">
1351
+ <h3 class="signature " id="all-instance_method">
1492
1352
 
1493
- - (<tt>Object</tt>) <strong>clear_cache</strong>
1353
+ - (<tt>Object</tt>) <strong>all</strong>(start_page = @options[&quot;page&quot;], &amp;block)
1494
1354
 
1495
1355
 
1496
1356
 
@@ -1499,13 +1359,33 @@ per_page.</p>
1499
1359
  </h3><div class="docstring">
1500
1360
  <div class="discussion">
1501
1361
 
1502
- <p>Clears all cached resources and associated values.</p>
1362
+ <p>Calls #each on every page with the passed in block</p>
1503
1363
 
1504
1364
 
1505
1365
  </div>
1506
1366
  </div>
1507
1367
  <div class="tags">
1368
+ <p class="tag_title">Parameters:</p>
1369
+ <ul class="param">
1508
1370
 
1371
+ <li>
1372
+
1373
+ <span class='name'>block</span>
1374
+
1375
+
1376
+ <span class='type'>(<tt>Block</tt>)</span>
1377
+
1378
+
1379
+
1380
+ &mdash;
1381
+ <div class='inline'>
1382
+ <p>Passed to #each</p>
1383
+ </div>
1384
+
1385
+ </li>
1386
+
1387
+ </ul>
1388
+
1509
1389
 
1510
1390
  </div><table class="source_code">
1511
1391
  <tr>
@@ -1513,21 +1393,15 @@ per_page.</p>
1513
1393
  <pre class="lines">
1514
1394
 
1515
1395
 
1516
- 268
1517
- 269
1518
- 270
1519
- 271
1520
- 272
1521
- 273</pre>
1396
+ 179
1397
+ 180
1398
+ 181</pre>
1522
1399
  </td>
1523
1400
  <td>
1524
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 268</span>
1401
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 179</span>
1525
1402
 
1526
- <span class='kw'>def</span> <span class='id identifier rubyid_clear_cache'>clear_cache</span>
1527
- <span class='ivar'>@resources</span> <span class='op'>=</span> <span class='kw'>nil</span>
1528
- <span class='ivar'>@count</span> <span class='op'>=</span> <span class='kw'>nil</span>
1529
- <span class='ivar'>@next_page</span> <span class='op'>=</span> <span class='kw'>nil</span>
1530
- <span class='ivar'>@prev_page</span> <span class='op'>=</span> <span class='kw'>nil</span>
1403
+ <span class='kw'>def</span> <span class='id identifier rubyid_all'>all</span><span class='lparen'>(</span><span class='id identifier rubyid_start_page'>start_page</span> <span class='op'>=</span> <span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1404
+ <span class='id identifier rubyid__all'>_all</span><span class='lparen'>(</span><span class='id identifier rubyid_start_page'>start_page</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1531
1405
  <span class='kw'>end</span></pre>
1532
1406
  </td>
1533
1407
  </tr>
@@ -1535,9 +1409,9 @@ per_page.</p>
1535
1409
  </div>
1536
1410
 
1537
1411
  <div class="method_details ">
1538
- <h3 class="signature " id="count-instance_method">
1412
+ <h3 class="signature " id="all!-instance_method">
1539
1413
 
1540
- - (<tt>Number</tt>) <strong>count</strong>
1414
+ - (<tt>Object</tt>) <strong>all!</strong>(start_page = @options[&quot;page&quot;], &amp;block)
1541
1415
 
1542
1416
 
1543
1417
 
@@ -1546,49 +1420,49 @@ per_page.</p>
1546
1420
  </h3><div class="docstring">
1547
1421
  <div class="discussion">
1548
1422
 
1549
- <p>The total number of resources server-side (disregarding pagination).</p>
1423
+ <p>Calls #each on every page with the passed in block</p>
1550
1424
 
1551
1425
 
1552
1426
  </div>
1553
1427
  </div>
1554
1428
  <div class="tags">
1555
-
1556
- <p class="tag_title">Returns:</p>
1557
- <ul class="return">
1429
+ <p class="tag_title">Parameters:</p>
1430
+ <ul class="param">
1558
1431
 
1559
1432
  <li>
1560
1433
 
1434
+ <span class='name'>block</span>
1561
1435
 
1562
- <span class='type'>(<tt>Number</tt>)</span>
1436
+
1437
+ <span class='type'>(<tt>Block</tt>)</span>
1563
1438
 
1564
1439
 
1565
1440
 
1566
1441
  &mdash;
1567
1442
  <div class='inline'>
1568
- <p>The total number of resources server-side (disregarding pagination).</p>
1443
+ <p>Passed to #each</p>
1569
1444
  </div>
1570
1445
 
1571
1446
  </li>
1572
1447
 
1573
1448
  </ul>
1574
1449
 
1450
+
1575
1451
  </div><table class="source_code">
1576
1452
  <tr>
1577
1453
  <td>
1578
1454
  <pre class="lines">
1579
1455
 
1580
1456
 
1581
- 85
1582
- 86
1583
- 87
1584
- 88</pre>
1457
+ 173
1458
+ 174
1459
+ 175</pre>
1585
1460
  </td>
1586
1461
  <td>
1587
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 85</span>
1462
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 173</span>
1588
1463
 
1589
- <span class='kw'>def</span> <span class='id identifier rubyid_count'>count</span>
1590
- <span class='id identifier rubyid_fetch'>fetch</span>
1591
- <span class='ivar'>@count</span> <span class='op'>||</span> <span class='op'>-</span><span class='int'>1</span>
1464
+ <span class='kw'>def</span> <span class='id identifier rubyid_all!'>all!</span><span class='lparen'>(</span><span class='id identifier rubyid_start_page'>start_page</span> <span class='op'>=</span> <span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1465
+ <span class='id identifier rubyid__all'>_all</span><span class='lparen'>(</span><span class='id identifier rubyid_start_page'>start_page</span><span class='comma'>,</span> <span class='symbol'>:bang</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1592
1466
  <span class='kw'>end</span></pre>
1593
1467
  </td>
1594
1468
  </tr>
@@ -1596,9 +1470,9 @@ per_page.</p>
1596
1470
  </div>
1597
1471
 
1598
1472
  <div class="method_details ">
1599
- <h3 class="signature " id="create-instance_method">
1473
+ <h3 class="signature " id="clear_cache-instance_method">
1600
1474
 
1601
- - (<tt>Object</tt>) <strong>create</strong>(attributes = {})
1475
+ - (<tt>Object</tt>) <strong>clear_cache</strong>
1602
1476
 
1603
1477
 
1604
1478
 
@@ -1607,35 +1481,13 @@ per_page.</p>
1607
1481
  </h3><div class="docstring">
1608
1482
  <div class="discussion">
1609
1483
 
1610
- <p>Passes arguments and the proper path to the resource class method.</p>
1484
+ <p>Clears all cached resources and associated values.</p>
1611
1485
 
1612
1486
 
1613
1487
  </div>
1614
1488
  </div>
1615
1489
  <div class="tags">
1616
- <p class="tag_title">Parameters:</p>
1617
- <ul class="param">
1618
1490
 
1619
- <li>
1620
-
1621
- <span class='name'>attributes</span>
1622
-
1623
-
1624
- <span class='type'>(<tt>Hash</tt>)</span>
1625
-
1626
-
1627
- <em class="default">(defaults to: <tt>{}</tt>)</em>
1628
-
1629
-
1630
- &mdash;
1631
- <div class='inline'>
1632
- <p>Attributes to pass to Create#create</p>
1633
- </div>
1634
-
1635
- </li>
1636
-
1637
- </ul>
1638
-
1639
1491
 
1640
1492
  </div><table class="source_code">
1641
1493
  <tr>
@@ -1643,49 +1495,21 @@ per_page.</p>
1643
1495
  <pre class="lines">
1644
1496
 
1645
1497
 
1646
- 61
1647
- 62
1648
- 63
1649
- 64</pre>
1650
- </td>
1651
- <td>
1652
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 61</span>
1653
-
1654
- <span class='kw'>def</span> <span class='id identifier rubyid_create'>create</span><span class='lparen'>(</span><span class='id identifier rubyid_attributes'>attributes</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span>
1655
- <span class='id identifier rubyid_attributes'>attributes</span><span class='period'>.</span><span class='id identifier rubyid_merge!'>merge!</span><span class='lparen'>(</span><span class='symbol'>:association</span> <span class='op'>=&gt;</span> <span class='ivar'>@association</span><span class='rparen'>)</span>
1656
- <span class='ivar'>@resource_class</span><span class='period'>.</span><span class='id identifier rubyid_create'>create</span><span class='lparen'>(</span><span class='ivar'>@client</span><span class='comma'>,</span> <span class='ivar'>@options</span><span class='period'>.</span><span class='id identifier rubyid_merge'>merge</span><span class='lparen'>(</span><span class='id identifier rubyid_attributes'>attributes</span><span class='rparen'>)</span><span class='rparen'>)</span>
1657
- <span class='kw'>end</span></pre>
1658
- </td>
1659
- </tr>
1660
- </table>
1661
- </div>
1662
-
1663
- <div class="method_details ">
1664
- <h3 class="signature " id="destroy-instance_method">
1665
-
1666
- - (<tt>Object</tt>) <strong>destroy</strong>(opts = {})
1667
-
1668
-
1669
-
1670
-
1671
-
1672
- </h3><table class="source_code">
1673
- <tr>
1674
- <td>
1675
- <pre class="lines">
1676
-
1677
-
1678
- 79
1679
- 80
1680
- 81
1681
- 82</pre>
1498
+ 234
1499
+ 235
1500
+ 236
1501
+ 237
1502
+ 238
1503
+ 239</pre>
1682
1504
  </td>
1683
1505
  <td>
1684
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 79</span>
1506
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 234</span>
1685
1507
 
1686
- <span class='kw'>def</span> <span class='id identifier rubyid_destroy'>destroy</span><span class='lparen'>(</span><span class='id identifier rubyid_opts'>opts</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span>
1687
- <span class='id identifier rubyid_opts'>opts</span><span class='period'>.</span><span class='id identifier rubyid_merge!'>merge!</span><span class='lparen'>(</span><span class='symbol'>:association</span> <span class='op'>=&gt;</span> <span class='id identifier rubyid_association'>association</span><span class='rparen'>)</span>
1688
- <span class='ivar'>@resource_class</span><span class='period'>.</span><span class='id identifier rubyid_destroy'>destroy</span><span class='lparen'>(</span><span class='ivar'>@client</span><span class='comma'>,</span> <span class='ivar'>@options</span><span class='period'>.</span><span class='id identifier rubyid_merge'>merge</span><span class='lparen'>(</span><span class='id identifier rubyid_opts'>opts</span><span class='rparen'>)</span><span class='rparen'>)</span>
1508
+ <span class='kw'>def</span> <span class='id identifier rubyid_clear_cache'>clear_cache</span>
1509
+ <span class='ivar'>@resources</span> <span class='op'>=</span> <span class='kw'>nil</span>
1510
+ <span class='ivar'>@count</span> <span class='op'>=</span> <span class='kw'>nil</span>
1511
+ <span class='ivar'>@next_page</span> <span class='op'>=</span> <span class='kw'>nil</span>
1512
+ <span class='ivar'>@prev_page</span> <span class='op'>=</span> <span class='kw'>nil</span>
1689
1513
  <span class='kw'>end</span></pre>
1690
1514
  </td>
1691
1515
  </tr>
@@ -1693,9 +1517,9 @@ per_page.</p>
1693
1517
  </div>
1694
1518
 
1695
1519
  <div class="method_details ">
1696
- <h3 class="signature " id="each_page-instance_method">
1520
+ <h3 class="signature " id="count-instance_method">
1697
1521
 
1698
- - (<tt>Object</tt>) <strong>each_page</strong>(&amp;block)
1522
+ - (<tt>Number</tt>) <strong>count</strong>
1699
1523
 
1700
1524
 
1701
1525
 
@@ -1704,79 +1528,49 @@ per_page.</p>
1704
1528
  </h3><div class="docstring">
1705
1529
  <div class="discussion">
1706
1530
 
1707
- <p>Calls #each on every page with the passed in block</p>
1531
+ <p>The total number of resources server-side (disregarding pagination).</p>
1708
1532
 
1709
1533
 
1710
1534
  </div>
1711
1535
  </div>
1712
1536
  <div class="tags">
1713
- <p class="tag_title">Parameters:</p>
1714
- <ul class="param">
1537
+
1538
+ <p class="tag_title">Returns:</p>
1539
+ <ul class="return">
1715
1540
 
1716
1541
  <li>
1717
1542
 
1718
- <span class='name'>block</span>
1719
-
1720
1543
 
1721
- <span class='type'>(<tt>Block</tt>)</span>
1544
+ <span class='type'>(<tt>Number</tt>)</span>
1722
1545
 
1723
1546
 
1724
1547
 
1725
1548
  &mdash;
1726
1549
  <div class='inline'>
1727
- <p>Passed to #each</p>
1550
+ <p>The total number of resources server-side (disregarding pagination).</p>
1728
1551
  </div>
1729
1552
 
1730
1553
  </li>
1731
1554
 
1732
1555
  </ul>
1733
1556
 
1734
-
1735
1557
  </div><table class="source_code">
1736
1558
  <tr>
1737
1559
  <td>
1738
1560
  <pre class="lines">
1739
1561
 
1740
1562
 
1741
- 206
1742
- 207
1743
- 208
1744
- 209
1745
- 210
1746
- 211
1747
- 212
1748
- 213
1749
- 214
1750
- 215
1751
- 216
1752
- 217
1753
- 218
1754
- 219
1755
- 220
1756
- 221
1757
- 222
1758
- 223</pre>
1563
+ 64
1564
+ 65
1565
+ 66
1566
+ 67</pre>
1759
1567
  </td>
1760
1568
  <td>
1761
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 206</span>
1762
-
1763
- <span class='kw'>def</span> <span class='id identifier rubyid_each_page'>each_page</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1764
- <span class='id identifier rubyid_page'>page</span><span class='lparen'>(</span><span class='kw'>nil</span><span class='rparen'>)</span>
1765
- <span class='id identifier rubyid_clear_cache'>clear_cache</span>
1569
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 64</span>
1766
1570
 
1767
- <span class='kw'>while</span> <span class='op'>!</span><span class='id identifier rubyid_empty?'>empty?</span>
1768
- <span class='id identifier rubyid_each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_resource'>resource</span><span class='op'>|</span>
1769
- <span class='id identifier rubyid_arguments'>arguments</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='id identifier rubyid_resource'>resource</span><span class='comma'>,</span> <span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='int'>1</span><span class='rbracket'>]</span>
1770
-
1771
- <span class='kw'>if</span> <span class='id identifier rubyid_block'>block</span><span class='period'>.</span><span class='id identifier rubyid_arity'>arity</span> <span class='op'>&gt;=</span> <span class='int'>0</span>
1772
- <span class='id identifier rubyid_arguments'>arguments</span> <span class='op'>=</span> <span class='id identifier rubyid_arguments'>arguments</span><span class='period'>.</span><span class='id identifier rubyid_take'>take</span><span class='lparen'>(</span><span class='id identifier rubyid_block'>block</span><span class='period'>.</span><span class='id identifier rubyid_arity'>arity</span><span class='rparen'>)</span>
1773
- <span class='kw'>end</span>
1774
-
1775
- <span class='id identifier rubyid_block'>block</span><span class='period'>.</span><span class='id identifier rubyid_call'>call</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_arguments'>arguments</span><span class='rparen'>)</span>
1776
- <span class='kw'>end</span>
1777
-
1778
- <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_next'>next</span>
1779
- <span class='kw'>end</span>
1571
+ <span class='kw'>def</span> <span class='id identifier rubyid_count'>count</span>
1572
+ <span class='id identifier rubyid_fetch'>fetch</span>
1573
+ <span class='ivar'>@count</span> <span class='op'>||</span> <span class='op'>-</span><span class='int'>1</span>
1780
1574
  <span class='kw'>end</span></pre>
1781
1575
  </td>
1782
1576
  </tr>
@@ -1784,9 +1578,9 @@ per_page.</p>
1784
1578
  </div>
1785
1579
 
1786
1580
  <div class="method_details ">
1787
- <h3 class="signature " id="fetch-instance_method">
1581
+ <h3 class="signature " id="count!-instance_method">
1788
1582
 
1789
- - (<tt>Object</tt>) <strong>fetch</strong>(reload = false)
1583
+ - (<tt>Number</tt>) <strong>count!</strong>
1790
1584
 
1791
1585
 
1792
1586
 
@@ -1795,117 +1589,49 @@ per_page.</p>
1795
1589
  </h3><div class="docstring">
1796
1590
  <div class="discussion">
1797
1591
 
1798
- <p>Executes actual GET from API and loads resources into proper class.</p>
1592
+ <p>The total number of resources server-side (disregarding pagination).</p>
1799
1593
 
1800
1594
 
1801
1595
  </div>
1802
1596
  </div>
1803
1597
  <div class="tags">
1804
- <p class="tag_title">Parameters:</p>
1805
- <ul class="param">
1598
+
1599
+ <p class="tag_title">Returns:</p>
1600
+ <ul class="return">
1806
1601
 
1807
1602
  <li>
1808
1603
 
1809
- <span class='name'>reload</span>
1810
-
1811
-
1812
- <span class='type'>(<tt>Boolean</tt>)</span>
1813
1604
 
1605
+ <span class='type'>(<tt>Number</tt>)</span>
1814
1606
 
1815
- <em class="default">(defaults to: <tt>false</tt>)</em>
1816
1607
 
1817
1608
 
1818
1609
  &mdash;
1819
1610
  <div class='inline'>
1820
- <p>Whether to disregard cache</p>
1611
+ <p>The total number of resources server-side (disregarding pagination).</p>
1821
1612
  </div>
1822
1613
 
1823
1614
  </li>
1824
1615
 
1825
1616
  </ul>
1826
1617
 
1827
-
1828
1618
  </div><table class="source_code">
1829
1619
  <tr>
1830
1620
  <td>
1831
1621
  <pre class="lines">
1832
1622
 
1833
1623
 
1834
- 160
1835
- 161
1836
- 162
1837
- 163
1838
- 164
1839
- 165
1840
- 166
1841
- 167
1842
- 168
1843
- 169
1844
- 170
1845
- 171
1846
- 172
1847
- 173
1848
- 174
1849
- 175
1850
- 176
1851
- 177
1852
- 178
1853
- 179
1854
- 180
1855
- 181
1856
- 182
1857
- 183
1858
- 184
1859
- 185
1860
- 186
1861
- 187
1862
- 188
1863
- 189
1864
- 190
1865
- 191
1866
- 192
1867
- 193
1868
- 194
1869
- 195</pre>
1624
+ 70
1625
+ 71
1626
+ 72
1627
+ 73</pre>
1870
1628
  </td>
1871
1629
  <td>
1872
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 160</span>
1873
-
1874
- <span class='kw'>def</span> <span class='id identifier rubyid_fetch'>fetch</span><span class='lparen'>(</span><span class='id identifier rubyid_reload'>reload</span> <span class='op'>=</span> <span class='kw'>false</span><span class='rparen'>)</span>
1875
- <span class='kw'>return</span> <span class='ivar'>@resources</span> <span class='kw'>if</span> <span class='ivar'>@resources</span> <span class='op'>&amp;&amp;</span> <span class='lparen'>(</span><span class='op'>!</span><span class='ivar'>@fetchable</span> <span class='op'>||</span> <span class='op'>!</span><span class='id identifier rubyid_reload'>reload</span><span class='rparen'>)</span>
1876
-
1877
- <span class='kw'>if</span> <span class='id identifier rubyid_association'>association</span> <span class='op'>&amp;&amp;</span> <span class='id identifier rubyid_association'>association</span><span class='period'>.</span><span class='id identifier rubyid_options'>options</span><span class='period'>.</span><span class='id identifier rubyid_parent'>parent</span> <span class='op'>&amp;&amp;</span> <span class='id identifier rubyid_association'>association</span><span class='period'>.</span><span class='id identifier rubyid_options'>options</span><span class='period'>.</span><span class='id identifier rubyid_parent'>parent</span><span class='period'>.</span><span class='id identifier rubyid_new_record?'>new_record?</span>
1878
- <span class='kw'>return</span> <span class='ivar'>@resources</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span>
1879
- <span class='kw'>end</span>
1630
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 70</span>
1880
1631
 
1881
- <span class='kw'>if</span> <span class='ivar'>@query</span>
1882
- <span class='id identifier rubyid_path'>path</span> <span class='op'>=</span> <span class='ivar'>@query</span>
1883
- <span class='ivar'>@query</span> <span class='op'>=</span> <span class='kw'>nil</span>
1884
- <span class='kw'>else</span>
1885
- <span class='id identifier rubyid_path'>path</span> <span class='op'>=</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_path'>path</span>
1886
- <span class='kw'>end</span>
1887
-
1888
- <span class='ivar'>@response</span> <span class='op'>=</span> <span class='ivar'>@client</span><span class='period'>.</span><span class='id identifier rubyid_connection'>connection</span><span class='period'>.</span><span class='id identifier rubyid_send'>send</span><span class='lparen'>(</span><span class='ivar'>@verb</span> <span class='op'>||</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>get</span><span class='tstring_end'>&quot;</span></span><span class='comma'>,</span> <span class='id identifier rubyid_path'>path</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_req'>req</span><span class='op'>|</span>
1889
- <span class='id identifier rubyid_opts'>opts</span> <span class='op'>=</span> <span class='ivar'>@options</span><span class='period'>.</span><span class='id identifier rubyid_delete_if'>delete_if</span> <span class='lbrace'>{</span><span class='op'>|</span><span class='id identifier rubyid_k'>k</span><span class='comma'>,</span> <span class='id identifier rubyid_v'>v</span><span class='op'>|</span> <span class='id identifier rubyid_v'>v</span><span class='period'>.</span><span class='id identifier rubyid_nil?'>nil?</span><span class='rbrace'>}</span>
1890
-
1891
- <span class='id identifier rubyid_req'>req</span><span class='period'>.</span><span class='id identifier rubyid_params'>params</span><span class='period'>.</span><span class='id identifier rubyid_merge!'>merge!</span><span class='lparen'>(</span><span class='symbol'>:include</span> <span class='op'>=&gt;</span> <span class='ivar'>@includes</span><span class='period'>.</span><span class='id identifier rubyid_join'>join</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>,</span><span class='tstring_end'>&quot;</span></span><span class='rparen'>)</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='ivar'>@includes</span><span class='period'>.</span><span class='id identifier rubyid_any?'>any?</span>
1892
-
1893
- <span class='kw'>if</span> <span class='qwords_beg'>%w{</span><span class='tstring_content'>put</span><span class='words_sep'> </span><span class='tstring_content'>post</span><span class='words_sep'>}</span><span class='period'>.</span><span class='id identifier rubyid_include?'>include?</span><span class='lparen'>(</span><span class='ivar'>@verb</span><span class='period'>.</span><span class='id identifier rubyid_to_s'>to_s</span><span class='rparen'>)</span>
1894
- <span class='id identifier rubyid_req'>req</span><span class='period'>.</span><span class='id identifier rubyid_body'>body</span> <span class='op'>=</span> <span class='id identifier rubyid_opts'>opts</span>
1895
- <span class='kw'>else</span>
1896
- <span class='id identifier rubyid_req'>req</span><span class='period'>.</span><span class='id identifier rubyid_params'>params</span><span class='period'>.</span><span class='id identifier rubyid_merge!'>merge!</span><span class='lparen'>(</span><span class='id identifier rubyid_opts'>opts</span><span class='rparen'>)</span>
1897
- <span class='kw'>end</span>
1898
- <span class='kw'>end</span>
1899
-
1900
- <span class='id identifier rubyid_body'>body</span> <span class='op'>=</span> <span class='ivar'>@response</span><span class='period'>.</span><span class='id identifier rubyid_body'>body</span><span class='period'>.</span><span class='id identifier rubyid_dup'>dup</span>
1901
-
1902
- <span class='id identifier rubyid_results'>results</span> <span class='op'>=</span> <span class='id identifier rubyid_body'>body</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='ivar'>@resource_class</span><span class='period'>.</span><span class='id identifier rubyid_model_key'>model_key</span><span class='rparen'>)</span> <span class='op'>||</span> <span class='id identifier rubyid_body'>body</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>results</span><span class='tstring_end'>&quot;</span></span><span class='rparen'>)</span>
1903
- <span class='ivar'>@resources</span> <span class='op'>=</span> <span class='id identifier rubyid_results'>results</span><span class='period'>.</span><span class='id identifier rubyid_map'>map</span> <span class='lbrace'>{</span><span class='op'>|</span><span class='id identifier rubyid_res'>res</span><span class='op'>|</span> <span class='ivar'>@resource_class</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='ivar'>@client</span><span class='comma'>,</span> <span class='id identifier rubyid_res'>res</span><span class='rparen'>)</span><span class='rbrace'>}</span>
1904
-
1905
- <span class='id identifier rubyid_set_page_and_count'>set_page_and_count</span><span class='lparen'>(</span><span class='id identifier rubyid_body'>body</span><span class='rparen'>)</span>
1906
- <span class='id identifier rubyid_set_includes'>set_includes</span><span class='lparen'>(</span><span class='ivar'>@resources</span><span class='comma'>,</span> <span class='ivar'>@includes</span><span class='comma'>,</span> <span class='id identifier rubyid_body'>body</span><span class='rparen'>)</span>
1907
-
1908
- <span class='ivar'>@resources</span>
1632
+ <span class='kw'>def</span> <span class='id identifier rubyid_count!'>count!</span>
1633
+ <span class='id identifier rubyid_fetch!'>fetch!</span>
1634
+ <span class='ivar'>@count</span> <span class='op'>||</span> <span class='op'>-</span><span class='int'>1</span>
1909
1635
  <span class='kw'>end</span></pre>
1910
1636
  </td>
1911
1637
  </tr>
@@ -1913,9 +1639,9 @@ per_page.</p>
1913
1639
  </div>
1914
1640
 
1915
1641
  <div class="method_details ">
1916
- <h3 class="signature " id="find-instance_method">
1642
+ <h3 class="signature " id="each_page-instance_method">
1917
1643
 
1918
- - (<tt>Object</tt>) <strong>find</strong>(opts = {})
1644
+ - (<tt>Object</tt>) <strong>each_page</strong>(*args, &amp;block)
1919
1645
 
1920
1646
 
1921
1647
 
@@ -1927,17 +1653,17 @@ per_page.</p>
1927
1653
  <pre class="lines">
1928
1654
 
1929
1655
 
1930
- 67
1931
- 68
1932
- 69
1933
- 70</pre>
1656
+ 188
1657
+ 189
1658
+ 190
1659
+ 191</pre>
1934
1660
  </td>
1935
1661
  <td>
1936
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 67</span>
1662
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 188</span>
1937
1663
 
1938
- <span class='kw'>def</span> <span class='id identifier rubyid_find'>find</span><span class='lparen'>(</span><span class='id identifier rubyid_opts'>opts</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span>
1939
- <span class='id identifier rubyid_opts'>opts</span><span class='period'>.</span><span class='id identifier rubyid_merge!'>merge!</span><span class='lparen'>(</span><span class='symbol'>:association</span> <span class='op'>=&gt;</span> <span class='ivar'>@association</span><span class='rparen'>)</span>
1940
- <span class='ivar'>@resource_class</span><span class='period'>.</span><span class='id identifier rubyid_find'>find</span><span class='lparen'>(</span><span class='ivar'>@client</span><span class='comma'>,</span> <span class='ivar'>@options</span><span class='period'>.</span><span class='id identifier rubyid_merge'>merge</span><span class='lparen'>(</span><span class='id identifier rubyid_opts'>opts</span><span class='rparen'>)</span><span class='rparen'>)</span>
1664
+ <span class='kw'>def</span> <span class='id identifier rubyid_each_page'>each_page</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1665
+ <span class='id identifier rubyid_warn'>warn</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>ZendeskAPI::Collection#each_page is deprecated, please use ZendeskAPI::Collection#all</span><span class='tstring_end'>&quot;</span></span>
1666
+ <span class='id identifier rubyid_all'>all</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1941
1667
  <span class='kw'>end</span></pre>
1942
1668
  </td>
1943
1669
  </tr>
@@ -1945,51 +1671,31 @@ per_page.</p>
1945
1671
  </div>
1946
1672
 
1947
1673
  <div class="method_details ">
1948
- <h3 class="signature " id="first_page?-instance_method">
1674
+ <h3 class="signature " id="each_page!-instance_method">
1949
1675
 
1950
- - (<tt>Boolean</tt>) <strong>first_page?</strong>
1676
+ - (<tt>Object</tt>) <strong>each_page!</strong>(*args, &amp;block)
1951
1677
 
1952
1678
 
1953
1679
 
1954
1680
 
1955
1681
 
1956
- </h3><div class="docstring">
1957
- <div class="discussion">
1958
-
1959
-
1960
- </div>
1961
- </div>
1962
- <div class="tags">
1963
-
1964
- <p class="tag_title">Returns:</p>
1965
- <ul class="return">
1966
-
1967
- <li>
1968
-
1969
-
1970
- <span class='type'>(<tt>Boolean</tt>)</span>
1971
-
1972
-
1973
-
1974
- </li>
1975
-
1976
- </ul>
1977
-
1978
- </div><table class="source_code">
1682
+ </h3><table class="source_code">
1979
1683
  <tr>
1980
1684
  <td>
1981
1685
  <pre class="lines">
1982
1686
 
1983
1687
 
1984
- 106
1985
- 107
1986
- 108</pre>
1688
+ 183
1689
+ 184
1690
+ 185
1691
+ 186</pre>
1987
1692
  </td>
1988
1693
  <td>
1989
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 106</span>
1694
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 183</span>
1990
1695
 
1991
- <span class='kw'>def</span> <span class='id identifier rubyid_first_page?'>first_page?</span>
1992
- <span class='op'>!</span><span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='period'>.</span><span class='id identifier rubyid_to_i'>to_i</span> <span class='op'>&lt;=</span> <span class='int'>1</span>
1696
+ <span class='kw'>def</span> <span class='id identifier rubyid_each_page!'>each_page!</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1697
+ <span class='id identifier rubyid_warn'>warn</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>ZendeskAPI::Collection#each_page! is deprecated, please use ZendeskAPI::Collection#all!</span><span class='tstring_end'>&quot;</span></span>
1698
+ <span class='id identifier rubyid_all!'>all!</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1993
1699
  <span class='kw'>end</span></pre>
1994
1700
  </td>
1995
1701
  </tr>
@@ -1997,9 +1703,9 @@ per_page.</p>
1997
1703
  </div>
1998
1704
 
1999
1705
  <div class="method_details ">
2000
- <h3 class="signature " id="format_headers-instance_method">
1706
+ <h3 class="signature " id="fetch-instance_method">
2001
1707
 
2002
- - (<tt>Object</tt>) <strong>format_headers</strong>
1708
+ - (<tt>Object</tt>) <strong>fetch</strong>(*args)
2003
1709
 
2004
1710
 
2005
1711
 
@@ -2011,15 +1717,19 @@ per_page.</p>
2011
1717
  <pre class="lines">
2012
1718
 
2013
1719
 
2014
- 37
2015
- 38
2016
- 39</pre>
1720
+ 155
1721
+ 156
1722
+ 157
1723
+ 158
1724
+ 159</pre>
2017
1725
  </td>
2018
1726
  <td>
2019
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/console/extensions.rb', line 37</span>
1727
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 155</span>
2020
1728
 
2021
- <span class='kw'>def</span> <span class='id identifier rubyid_format_headers'>format_headers</span>
2022
- <span class='ivar'>@resource_class</span><span class='period'>.</span><span class='id identifier rubyid_format_headers'>format_headers</span>
1729
+ <span class='kw'>def</span> <span class='id identifier rubyid_fetch'>fetch</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span>
1730
+ <span class='id identifier rubyid_fetch!'>fetch!</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span>
1731
+ <span class='kw'>rescue</span> <span class='const'>Faraday</span><span class='op'>::</span><span class='const'>Error</span><span class='op'>::</span><span class='const'>ClientError</span> <span class='op'>=&gt;</span> <span class='id identifier rubyid_e'>e</span>
1732
+ <span class='lbracket'>[</span><span class='rbracket'>]</span>
2023
1733
  <span class='kw'>end</span></pre>
2024
1734
  </td>
2025
1735
  </tr>
@@ -2027,9 +1737,9 @@ per_page.</p>
2027
1737
  </div>
2028
1738
 
2029
1739
  <div class="method_details ">
2030
- <h3 class="signature " id="include-instance_method">
1740
+ <h3 class="signature " id="fetch!-instance_method">
2031
1741
 
2032
- - (<tt>Object</tt>) <strong>include</strong>(*sideloads)
1742
+ - (<tt>Object</tt>) <strong>fetch!</strong>(reload = false)
2033
1743
 
2034
1744
 
2035
1745
 
@@ -2038,7 +1748,7 @@ per_page.</p>
2038
1748
  </h3><div class="docstring">
2039
1749
  <div class="discussion">
2040
1750
 
2041
- <p>Adds an item (or items) to the list of side-loaded resources to request</p>
1751
+ <p>Executes actual GET from API and loads resources into proper class.</p>
2042
1752
 
2043
1753
 
2044
1754
  </div>
@@ -2049,26 +1759,24 @@ per_page.</p>
2049
1759
 
2050
1760
  <li>
2051
1761
 
2052
- <span class='name'>sideloads</span>
1762
+ <span class='name'>reload</span>
2053
1763
 
2054
1764
 
2055
- <span class='type'>(<tt>Hash</tt>)</span>
1765
+ <span class='type'>(<tt>Boolean</tt>)</span>
1766
+
2056
1767
 
1768
+ <em class="default">(defaults to: <tt>false</tt>)</em>
2057
1769
 
2058
1770
 
2059
1771
  &mdash;
2060
1772
  <div class='inline'>
2061
- <p>a customizable set of options</p>
1773
+ <p>Whether to disregard cache</p>
2062
1774
  </div>
2063
1775
 
2064
1776
  </li>
2065
1777
 
2066
1778
  </ul>
2067
1779
 
2068
-
2069
-
2070
-
2071
-
2072
1780
 
2073
1781
  </div><table class="source_code">
2074
1782
  <tr>
@@ -2076,15 +1784,35 @@ per_page.</p>
2076
1784
  <pre class="lines">
2077
1785
 
2078
1786
 
2079
- 132
2080
- 133
2081
- 134</pre>
1787
+ 141
1788
+ 142
1789
+ 143
1790
+ 144
1791
+ 145
1792
+ 146
1793
+ 147
1794
+ 148
1795
+ 149
1796
+ 150
1797
+ 151
1798
+ 152
1799
+ 153</pre>
2082
1800
  </td>
2083
1801
  <td>
2084
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 132</span>
1802
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 141</span>
2085
1803
 
2086
- <span class='kw'>def</span> <span class='id identifier rubyid_include'>include</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_sideloads'>sideloads</span><span class='rparen'>)</span>
2087
- <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_tap'>tap</span> <span class='lbrace'>{</span> <span class='ivar'>@includes</span><span class='period'>.</span><span class='id identifier rubyid_concat'>concat</span><span class='lparen'>(</span><span class='id identifier rubyid_sideloads'>sideloads</span><span class='period'>.</span><span class='id identifier rubyid_map'>map</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='symbol'>:to_s</span><span class='rparen'>)</span><span class='rparen'>)</span> <span class='rbrace'>}</span>
1804
+ <span class='kw'>def</span> <span class='id identifier rubyid_fetch!'>fetch!</span><span class='lparen'>(</span><span class='id identifier rubyid_reload'>reload</span> <span class='op'>=</span> <span class='kw'>false</span><span class='rparen'>)</span>
1805
+ <span class='kw'>if</span> <span class='ivar'>@resources</span> <span class='op'>&amp;&amp;</span> <span class='lparen'>(</span><span class='op'>!</span><span class='ivar'>@fetchable</span> <span class='op'>||</span> <span class='op'>!</span><span class='id identifier rubyid_reload'>reload</span><span class='rparen'>)</span>
1806
+ <span class='kw'>return</span> <span class='ivar'>@resources</span>
1807
+ <span class='kw'>elsif</span> <span class='id identifier rubyid_association'>association</span> <span class='op'>&amp;&amp;</span> <span class='id identifier rubyid_association'>association</span><span class='period'>.</span><span class='id identifier rubyid_options'>options</span><span class='period'>.</span><span class='id identifier rubyid_parent'>parent</span> <span class='op'>&amp;&amp;</span> <span class='id identifier rubyid_association'>association</span><span class='period'>.</span><span class='id identifier rubyid_options'>options</span><span class='period'>.</span><span class='id identifier rubyid_parent'>parent</span><span class='period'>.</span><span class='id identifier rubyid_new_record?'>new_record?</span>
1808
+ <span class='kw'>return</span> <span class='ivar'>@resources</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span>
1809
+ <span class='kw'>end</span>
1810
+
1811
+ <span class='ivar'>@response</span> <span class='op'>=</span> <span class='id identifier rubyid_get_response'>get_response</span><span class='lparen'>(</span><span class='ivar'>@query</span> <span class='op'>||</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_path'>path</span><span class='rparen'>)</span>
1812
+ <span class='id identifier rubyid_handle_response'>handle_response</span><span class='lparen'>(</span><span class='ivar'>@response</span><span class='period'>.</span><span class='id identifier rubyid_body'>body</span><span class='period'>.</span><span class='id identifier rubyid_dup'>dup</span><span class='rparen'>)</span>
1813
+
1814
+ <span class='ivar'>@query</span> <span class='op'>=</span> <span class='kw'>nil</span>
1815
+ <span class='ivar'>@resources</span>
2088
1816
  <span class='kw'>end</span></pre>
2089
1817
  </td>
2090
1818
  </tr>
@@ -2092,9 +1820,9 @@ per_page.</p>
2092
1820
  </div>
2093
1821
 
2094
1822
  <div class="method_details ">
2095
- <h3 class="signature " id="last_page?-instance_method">
1823
+ <h3 class="signature " id="first_page?-instance_method">
2096
1824
 
2097
- - (<tt>Boolean</tt>) <strong>last_page?</strong>
1825
+ - (<tt>Boolean</tt>) <strong>first_page?</strong>
2098
1826
 
2099
1827
 
2100
1828
 
@@ -2128,15 +1856,15 @@ per_page.</p>
2128
1856
  <pre class="lines">
2129
1857
 
2130
1858
 
2131
- 110
2132
- 111
2133
- 112</pre>
1859
+ 91
1860
+ 92
1861
+ 93</pre>
2134
1862
  </td>
2135
1863
  <td>
2136
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 110</span>
1864
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 91</span>
2137
1865
 
2138
- <span class='kw'>def</span> <span class='id identifier rubyid_last_page?'>last_page?</span>
2139
- <span class='op'>!</span><span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='period'>.</span><span class='id identifier rubyid_to_i'>to_i</span> <span class='op'>*</span> <span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>per_page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='period'>.</span><span class='id identifier rubyid_to_i'>to_i</span> <span class='op'>&gt;=</span> <span class='id identifier rubyid_count'>count</span>
1866
+ <span class='kw'>def</span> <span class='id identifier rubyid_first_page?'>first_page?</span>
1867
+ <span class='op'>!</span><span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='period'>.</span><span class='id identifier rubyid_to_i'>to_i</span> <span class='op'>&lt;=</span> <span class='int'>1</span>
2140
1868
  <span class='kw'>end</span></pre>
2141
1869
  </td>
2142
1870
  </tr>
@@ -2144,9 +1872,9 @@ per_page.</p>
2144
1872
  </div>
2145
1873
 
2146
1874
  <div class="method_details ">
2147
- <h3 class="signature " id="loaded?-instance_method">
1875
+ <h3 class="signature " id="include-instance_method">
2148
1876
 
2149
- - (<tt>Boolean</tt>) <strong>loaded?</strong>
1877
+ - (<tt>Object</tt>) <strong>include</strong>(*sideloads)
2150
1878
 
2151
1879
 
2152
1880
 
@@ -2155,40 +1883,53 @@ per_page.</p>
2155
1883
  </h3><div class="docstring">
2156
1884
  <div class="discussion">
2157
1885
 
1886
+ <p>Adds an item (or items) to the list of side-loaded resources to request</p>
1887
+
2158
1888
 
2159
1889
  </div>
2160
1890
  </div>
2161
1891
  <div class="tags">
2162
-
2163
- <p class="tag_title">Returns:</p>
2164
- <ul class="return">
1892
+ <p class="tag_title">Parameters:</p>
1893
+ <ul class="param">
2165
1894
 
2166
1895
  <li>
2167
1896
 
1897
+ <span class='name'>sideloads</span>
1898
+
1899
+
1900
+ <span class='type'>(<tt>Hash</tt>)</span>
2168
1901
 
2169
- <span class='type'>(<tt>Boolean</tt>)</span>
2170
1902
 
2171
1903
 
1904
+ &mdash;
1905
+ <div class='inline'>
1906
+ <p>a customizable set of options</p>
1907
+ </div>
2172
1908
 
2173
1909
  </li>
2174
1910
 
2175
1911
  </ul>
2176
1912
 
1913
+
1914
+
1915
+
1916
+
1917
+
2177
1918
  </div><table class="source_code">
2178
1919
  <tr>
2179
1920
  <td>
2180
1921
  <pre class="lines">
2181
1922
 
2182
1923
 
2183
- 29
2184
- 30
2185
- 31</pre>
1924
+ 113
1925
+ 114
1926
+ 115</pre>
2186
1927
  </td>
2187
1928
  <td>
2188
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/console/extensions.rb', line 29</span>
1929
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 113</span>
2189
1930
 
2190
- <span class='kw'>def</span> <span class='id identifier rubyid_loaded?'>loaded?</span>
2191
- <span class='ivar'>@resources</span> <span class='op'>&amp;&amp;</span> <span class='ivar'>@resources</span><span class='period'>.</span><span class='id identifier rubyid_any?'>any?</span>
1931
+ <span class='kw'>def</span> <span class='id identifier rubyid_include'>include</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_sideloads'>sideloads</span><span class='rparen'>)</span>
1932
+ <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_tap'>tap</span> <span class='lbrace'>{</span> <span class='ivar'>@includes</span><span class='period'>.</span><span class='id identifier rubyid_concat'>concat</span><span class='lparen'>(</span><span class='id identifier rubyid_sideloads'>sideloads</span><span class='period'>.</span><span class='id identifier rubyid_map'>map</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='symbol'>:to_s</span><span class='rparen'>)</span><span class='rparen'>)</span> <span class='rbrace'>}</span>
2192
1933
  <span class='kw'>end</span></pre>
2193
1934
  </td>
2194
1935
  </tr>
@@ -2196,29 +1937,51 @@ per_page.</p>
2196
1937
  </div>
2197
1938
 
2198
1939
  <div class="method_details ">
2199
- <h3 class="signature " id="log_error-instance_method">
1940
+ <h3 class="signature " id="last_page?-instance_method">
2200
1941
 
2201
- - (<tt>Object</tt>) <strong>log_error</strong>(e, _)
1942
+ - (<tt>Boolean</tt>) <strong>last_page?</strong>
2202
1943
 
2203
1944
 
2204
1945
 
2205
1946
 
2206
1947
 
2207
- </h3><table class="source_code">
1948
+ </h3><div class="docstring">
1949
+ <div class="discussion">
1950
+
1951
+
1952
+ </div>
1953
+ </div>
1954
+ <div class="tags">
1955
+
1956
+ <p class="tag_title">Returns:</p>
1957
+ <ul class="return">
1958
+
1959
+ <li>
1960
+
1961
+
1962
+ <span class='type'>(<tt>Boolean</tt>)</span>
1963
+
1964
+
1965
+
1966
+ </li>
1967
+
1968
+ </ul>
1969
+
1970
+ </div><table class="source_code">
2208
1971
  <tr>
2209
1972
  <td>
2210
1973
  <pre class="lines">
2211
1974
 
2212
1975
 
2213
- 25
2214
- 26
2215
- 27</pre>
1976
+ 95
1977
+ 96
1978
+ 97</pre>
2216
1979
  </td>
2217
1980
  <td>
2218
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/console/extensions.rb', line 25</span>
1981
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 95</span>
2219
1982
 
2220
- <span class='kw'>def</span> <span class='id identifier rubyid_log_error'>log_error</span><span class='lparen'>(</span><span class='id identifier rubyid_e'>e</span><span class='comma'>,</span> <span class='id identifier rubyid__'>_</span><span class='rparen'>)</span>
2221
- <span class='id identifier rubyid_raise'>raise</span> <span class='id identifier rubyid_e'>e</span>
1983
+ <span class='kw'>def</span> <span class='id identifier rubyid_last_page?'>last_page?</span>
1984
+ <span class='op'>!</span><span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='period'>.</span><span class='id identifier rubyid_to_i'>to_i</span> <span class='op'>*</span> <span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>per_page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='period'>.</span><span class='id identifier rubyid_to_i'>to_i</span> <span class='op'>&gt;=</span> <span class='id identifier rubyid_count'>count</span>
2222
1985
  <span class='kw'>end</span></pre>
2223
1986
  </td>
2224
1987
  </tr>
@@ -2260,28 +2023,26 @@ returns the results.</p>
2260
2023
  <pre class="lines">
2261
2024
 
2262
2025
 
2263
- 237
2264
- 238
2265
- 239
2266
- 240
2267
- 241
2268
- 242
2269
- 243
2270
- 244
2271
- 245
2272
- 246
2273
- 247
2274
- 248</pre>
2026
+ 205
2027
+ 206
2028
+ 207
2029
+ 208
2030
+ 209
2031
+ 210
2032
+ 211
2033
+ 212
2034
+ 213
2035
+ 214
2036
+ 215</pre>
2275
2037
  </td>
2276
2038
  <td>
2277
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 237</span>
2039
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 205</span>
2278
2040
 
2279
2041
  <span class='kw'>def</span> <span class='kw'>next</span>
2280
2042
  <span class='kw'>if</span> <span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span>
2281
2043
  <span class='id identifier rubyid_clear_cache'>clear_cache</span>
2282
2044
  <span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span> <span class='op'>+=</span> <span class='int'>1</span>
2283
- <span class='kw'>elsif</span> <span class='ivar'>@next_page</span>
2284
- <span class='ivar'>@query</span> <span class='op'>=</span> <span class='ivar'>@next_page</span>
2045
+ <span class='kw'>elsif</span> <span class='ivar'>@query</span> <span class='op'>=</span> <span class='ivar'>@next_page</span>
2285
2046
  <span class='id identifier rubyid_fetch'>fetch</span><span class='lparen'>(</span><span class='kw'>true</span><span class='rparen'>)</span>
2286
2047
  <span class='kw'>else</span>
2287
2048
  <span class='id identifier rubyid_clear_cache'>clear_cache</span>
@@ -2291,32 +2052,6 @@ returns the results.</p>
2291
2052
  </td>
2292
2053
  </tr>
2293
2054
  </table>
2294
- </div>
2295
-
2296
- <div class="method_details ">
2297
- <h3 class="signature " id="orig_log_error-instance_method">
2298
-
2299
- - (<tt>Object</tt>) <strong>orig_log_error</strong>
2300
-
2301
-
2302
-
2303
-
2304
-
2305
- </h3><table class="source_code">
2306
- <tr>
2307
- <td>
2308
- <pre class="lines">
2309
-
2310
-
2311
- 23</pre>
2312
- </td>
2313
- <td>
2314
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/console/extensions.rb', line 23</span>
2315
-
2316
- <span class='kw'>alias</span> <span class='symbol'>:orig_log_error</span> <span class='symbol'>:log_error</span></pre>
2317
- </td>
2318
- </tr>
2319
- </table>
2320
2055
  </div>
2321
2056
 
2322
2057
  <div class="method_details ">
@@ -2363,14 +2098,14 @@ returns the results.</p>
2363
2098
  <pre class="lines">
2364
2099
 
2365
2100
 
2366
- 100
2367
- 101
2368
- 102
2369
- 103
2370
- 104</pre>
2101
+ 85
2102
+ 86
2103
+ 87
2104
+ 88
2105
+ 89</pre>
2371
2106
  </td>
2372
2107
  <td>
2373
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 100</span>
2108
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 85</span>
2374
2109
 
2375
2110
  <span class='kw'>def</span> <span class='id identifier rubyid_page'>page</span><span class='lparen'>(</span><span class='id identifier rubyid_number'>number</span><span class='rparen'>)</span>
2376
2111
  <span class='id identifier rubyid_clear_cache'>clear_cache</span> <span class='kw'>if</span> <span class='id identifier rubyid_number'>number</span>
@@ -2408,12 +2143,12 @@ returns the results.</p>
2408
2143
  <pre class="lines">
2409
2144
 
2410
2145
 
2411
- 154
2412
- 155
2413
- 156</pre>
2146
+ 135
2147
+ 136
2148
+ 137</pre>
2414
2149
  </td>
2415
2150
  <td>
2416
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 154</span>
2151
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 135</span>
2417
2152
 
2418
2153
  <span class='kw'>def</span> <span class='id identifier rubyid_path'>path</span>
2419
2154
  <span class='ivar'>@association</span><span class='period'>.</span><span class='id identifier rubyid_generate_path'>generate_path</span><span class='lparen'>(</span><span class='symbol'>:with_parent</span> <span class='op'>=&gt;</span> <span class='kw'>true</span><span class='rparen'>)</span>
@@ -2468,14 +2203,14 @@ execution.</p>
2468
2203
  <pre class="lines">
2469
2204
 
2470
2205
 
2471
- 92
2472
- 93
2473
- 94
2474
- 95
2475
- 96</pre>
2206
+ 77
2207
+ 78
2208
+ 79
2209
+ 80
2210
+ 81</pre>
2476
2211
  </td>
2477
2212
  <td>
2478
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 92</span>
2213
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 77</span>
2479
2214
 
2480
2215
  <span class='kw'>def</span> <span class='id identifier rubyid_per_page'>per_page</span><span class='lparen'>(</span><span class='id identifier rubyid_count'>count</span><span class='rparen'>)</span>
2481
2216
  <span class='id identifier rubyid_clear_cache'>clear_cache</span> <span class='kw'>if</span> <span class='id identifier rubyid_count'>count</span>
@@ -2522,28 +2257,26 @@ returns the results.</p>
2522
2257
  <pre class="lines">
2523
2258
 
2524
2259
 
2525
- 254
2526
- 255
2527
- 256
2528
- 257
2529
- 258
2530
- 259
2531
- 260
2532
- 261
2533
- 262
2534
- 263
2535
- 264
2536
- 265</pre>
2260
+ 221
2261
+ 222
2262
+ 223
2263
+ 224
2264
+ 225
2265
+ 226
2266
+ 227
2267
+ 228
2268
+ 229
2269
+ 230
2270
+ 231</pre>
2537
2271
  </td>
2538
2272
  <td>
2539
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 254</span>
2273
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 221</span>
2540
2274
 
2541
2275
  <span class='kw'>def</span> <span class='id identifier rubyid_prev'>prev</span>
2542
2276
  <span class='kw'>if</span> <span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span> <span class='op'>&amp;&amp;</span> <span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span> <span class='op'>&gt;</span> <span class='int'>1</span>
2543
2277
  <span class='id identifier rubyid_clear_cache'>clear_cache</span>
2544
2278
  <span class='ivar'>@options</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>page</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span> <span class='op'>-=</span> <span class='int'>1</span>
2545
- <span class='kw'>elsif</span> <span class='ivar'>@prev_page</span>
2546
- <span class='ivar'>@query</span> <span class='op'>=</span> <span class='ivar'>@prev_page</span>
2279
+ <span class='kw'>elsif</span> <span class='ivar'>@query</span> <span class='op'>=</span> <span class='ivar'>@prev_page</span>
2547
2280
  <span class='id identifier rubyid_fetch'>fetch</span><span class='lparen'>(</span><span class='kw'>true</span><span class='rparen'>)</span>
2548
2281
  <span class='kw'>else</span>
2549
2282
  <span class='id identifier rubyid_clear_cache'>clear_cache</span>
@@ -2642,13 +2375,13 @@ collection</p>
2642
2375
  <pre class="lines">
2643
2376
 
2644
2377
 
2645
- 228
2646
- 229
2647
- 230
2648
- 231</pre>
2378
+ 196
2379
+ 197
2380
+ 198
2381
+ 199</pre>
2649
2382
  </td>
2650
2383
  <td>
2651
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 228</span>
2384
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 196</span>
2652
2385
 
2653
2386
  <span class='kw'>def</span> <span class='id identifier rubyid_replace'>replace</span><span class='lparen'>(</span><span class='id identifier rubyid_collection'>collection</span><span class='rparen'>)</span>
2654
2387
  <span class='id identifier rubyid_raise'>raise</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>this collection is for </span><span class='embexpr_beg'>#{</span><span class='ivar'>@resource_class</span><span class='rbrace'>}</span><span class='tstring_end'>&quot;</span></span> <span class='kw'>if</span> <span class='id identifier rubyid_collection'>collection</span><span class='period'>.</span><span class='id identifier rubyid_any?'>any?</span><span class='lbrace'>{</span><span class='op'>|</span><span class='id identifier rubyid_r'>r</span><span class='op'>|</span> <span class='op'>!</span><span class='id identifier rubyid_r'>r</span><span class='period'>.</span><span class='id identifier rubyid_is_a?'>is_a?</span><span class='lparen'>(</span><span class='ivar'>@resource_class</span><span class='rparen'>)</span> <span class='rbrace'>}</span>
@@ -2703,35 +2436,74 @@ collection</p>
2703
2436
  <pre class="lines">
2704
2437
 
2705
2438
 
2706
- 116
2707
- 117
2708
- 118
2709
- 119
2710
- 120
2711
- 121
2712
- 122
2713
- 123
2714
- 124
2715
- 125
2716
- 126
2717
- 127
2718
- 128</pre>
2439
+ 101
2440
+ 102
2441
+ 103</pre>
2719
2442
  </td>
2720
2443
  <td>
2721
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 116</span>
2444
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 101</span>
2722
2445
 
2723
2446
  <span class='kw'>def</span> <span class='id identifier rubyid_save'>save</span>
2724
- <span class='kw'>if</span> <span class='ivar'>@resources</span>
2725
- <span class='ivar'>@resources</span><span class='period'>.</span><span class='id identifier rubyid_map!'>map!</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_item'>item</span><span class='op'>|</span>
2726
- <span class='kw'>unless</span> <span class='op'>!</span><span class='id identifier rubyid_item'>item</span><span class='period'>.</span><span class='id identifier rubyid_respond_to?'>respond_to?</span><span class='lparen'>(</span><span class='symbol'>:save</span><span class='rparen'>)</span> <span class='op'>||</span> <span class='id identifier rubyid_item'>item</span><span class='period'>.</span><span class='id identifier rubyid_changes'>changes</span><span class='period'>.</span><span class='id identifier rubyid_empty?'>empty?</span>
2727
- <span class='id identifier rubyid_item'>item</span><span class='period'>.</span><span class='id identifier rubyid_save'>save</span>
2728
- <span class='kw'>end</span>
2447
+ <span class='id identifier rubyid__save'>_save</span>
2448
+ <span class='kw'>end</span></pre>
2449
+ </td>
2450
+ </tr>
2451
+ </table>
2452
+ </div>
2453
+
2454
+ <div class="method_details ">
2455
+ <h3 class="signature " id="save!-instance_method">
2456
+
2457
+ - (<tt><span class='object_link'><a href="" title="ZendeskAPI::Collection (class)">Collection</a></span></tt>) <strong>save!</strong>
2458
+
2729
2459
 
2730
- <span class='id identifier rubyid_item'>item</span>
2731
- <span class='kw'>end</span>
2732
- <span class='kw'>end</span>
2460
+
2733
2461
 
2734
- <span class='kw'>self</span>
2462
+
2463
+ </h3><div class="docstring">
2464
+ <div class="discussion">
2465
+
2466
+ <p>Saves all newly created resources stored in this collection.</p>
2467
+
2468
+
2469
+ </div>
2470
+ </div>
2471
+ <div class="tags">
2472
+
2473
+ <p class="tag_title">Returns:</p>
2474
+ <ul class="return">
2475
+
2476
+ <li>
2477
+
2478
+
2479
+ <span class='type'>(<tt><span class='object_link'><a href="" title="ZendeskAPI::Collection (class)">Collection</a></span></tt>)</span>
2480
+
2481
+
2482
+
2483
+ &mdash;
2484
+ <div class='inline'>
2485
+ <p>self</p>
2486
+ </div>
2487
+
2488
+ </li>
2489
+
2490
+ </ul>
2491
+
2492
+ </div><table class="source_code">
2493
+ <tr>
2494
+ <td>
2495
+ <pre class="lines">
2496
+
2497
+
2498
+ 107
2499
+ 108
2500
+ 109</pre>
2501
+ </td>
2502
+ <td>
2503
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 107</span>
2504
+
2505
+ <span class='kw'>def</span> <span class='id identifier rubyid_save!'>save!</span>
2506
+ <span class='id identifier rubyid__save'>_save</span><span class='lparen'>(</span><span class='symbol'>:save!</span><span class='rparen'>)</span>
2735
2507
  <span class='kw'>end</span></pre>
2736
2508
  </td>
2737
2509
  </tr>
@@ -2764,12 +2536,12 @@ collection</p>
2764
2536
  <pre class="lines">
2765
2537
 
2766
2538
 
2767
- 200
2768
- 201
2769
- 202</pre>
2539
+ 162
2540
+ 163
2541
+ 164</pre>
2770
2542
  </td>
2771
2543
  <td>
2772
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 200</span>
2544
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 162</span>
2773
2545
 
2774
2546
  <span class='kw'>def</span> <span class='id identifier rubyid_to_a'>to_a</span>
2775
2547
  <span class='id identifier rubyid_fetch'>fetch</span>
@@ -2780,31 +2552,40 @@ collection</p>
2780
2552
  </div>
2781
2553
 
2782
2554
  <div class="method_details ">
2783
- <h3 class="signature " id="update-instance_method">
2555
+ <h3 class="signature " id="to_a!-instance_method">
2784
2556
 
2785
- - (<tt>Object</tt>) <strong>update</strong>(opts = {})
2557
+ - (<tt>Object</tt>) <strong>to_a!</strong>
2786
2558
 
2787
2559
 
2788
2560
 
2789
2561
 
2790
2562
 
2791
- </h3><table class="source_code">
2563
+ </h3><div class="docstring">
2564
+ <div class="discussion">
2565
+
2566
+ <p>Alias for fetch!(false)</p>
2567
+
2568
+
2569
+ </div>
2570
+ </div>
2571
+ <div class="tags">
2572
+
2573
+
2574
+ </div><table class="source_code">
2792
2575
  <tr>
2793
2576
  <td>
2794
2577
  <pre class="lines">
2795
2578
 
2796
2579
 
2797
- 73
2798
- 74
2799
- 75
2800
- 76</pre>
2580
+ 167
2581
+ 168
2582
+ 169</pre>
2801
2583
  </td>
2802
2584
  <td>
2803
- <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 73</span>
2585
+ <pre class="code"><span class="info file"># File 'lib/zendesk_api/collection.rb', line 167</span>
2804
2586
 
2805
- <span class='kw'>def</span> <span class='id identifier rubyid_update'>update</span><span class='lparen'>(</span><span class='id identifier rubyid_opts'>opts</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span>
2806
- <span class='id identifier rubyid_opts'>opts</span><span class='period'>.</span><span class='id identifier rubyid_merge!'>merge!</span><span class='lparen'>(</span><span class='symbol'>:association</span> <span class='op'>=&gt;</span> <span class='ivar'>@association</span><span class='rparen'>)</span>
2807
- <span class='ivar'>@resource_class</span><span class='period'>.</span><span class='id identifier rubyid_update'>update</span><span class='lparen'>(</span><span class='ivar'>@client</span><span class='comma'>,</span> <span class='ivar'>@options</span><span class='period'>.</span><span class='id identifier rubyid_merge'>merge</span><span class='lparen'>(</span><span class='id identifier rubyid_opts'>opts</span><span class='rparen'>)</span><span class='rparen'>)</span>
2587
+ <span class='kw'>def</span> <span class='id identifier rubyid_to_a!'>to_a!</span>
2588
+ <span class='id identifier rubyid_fetch!'>fetch!</span>
2808
2589
  <span class='kw'>end</span></pre>
2809
2590
  </td>
2810
2591
  </tr>
@@ -2816,9 +2597,9 @@ collection</p>
2816
2597
  </div>
2817
2598
 
2818
2599
  <div id="footer">
2819
- Generated on Mon Feb 11 17:45:41 2013 by
2600
+ Generated on Wed May 15 18:59:36 2013 by
2820
2601
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
2821
- 0.8.4.1 (ruby-1.9.3).
2602
+ 0.8.5.2 (ruby-1.9.3).
2822
2603
  </div>
2823
2604
 
2824
2605
  </body>