qo 0.2.0 → 0.2.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (44) hide show
  1. checksums.yaml +5 -5
  2. data/.yardopts +3 -0
  3. data/README.md +35 -2
  4. data/Rakefile +65 -13
  5. data/docs/Qo.html +165 -0
  6. data/docs/Qo/Exceptions.html +160 -0
  7. data/docs/Qo/Exceptions/MultipleMatchersProvided.html +257 -0
  8. data/docs/Qo/Exceptions/NoMatchersProvided.html +257 -0
  9. data/docs/Qo/Exceptions/NotAllGuardMatchersProvided.html +260 -0
  10. data/docs/Qo/Helpers.html +382 -0
  11. data/docs/Qo/Matchers.html +169 -0
  12. data/docs/Qo/Matchers/ArrayMatcher.html +459 -0
  13. data/docs/Qo/Matchers/BaseMatcher.html +493 -0
  14. data/docs/Qo/Matchers/GuardBlockMatcher.html +471 -0
  15. data/docs/Qo/Matchers/HashMatcher.html +445 -0
  16. data/docs/Qo/Matchers/PatternMatch.html +551 -0
  17. data/docs/Qo/PublicApi.html +867 -0
  18. data/docs/_index.html +258 -0
  19. data/docs/class_list.html +51 -0
  20. data/docs/css/common.css +1 -0
  21. data/docs/css/full_list.css +58 -0
  22. data/docs/css/style.css +499 -0
  23. data/docs/file.README.html +701 -0
  24. data/docs/file_list.html +56 -0
  25. data/docs/frames.html +17 -0
  26. data/docs/img/qo_logo.png +0 -0
  27. data/docs/index.html +701 -0
  28. data/docs/js/app.js +248 -0
  29. data/docs/js/full_list.js +216 -0
  30. data/docs/js/jquery.js +4 -0
  31. data/docs/method_list.html +227 -0
  32. data/docs/top-level-namespace.html +110 -0
  33. data/img/whoa_lemur.png +0 -0
  34. data/lib/qo/exceptions.rb +8 -4
  35. data/lib/qo/matchers/array_matcher.rb +34 -12
  36. data/lib/qo/matchers/base_matcher.rb +26 -11
  37. data/lib/qo/matchers/guard_block_matcher.rb +17 -3
  38. data/lib/qo/matchers/hash_matcher.rb +32 -23
  39. data/lib/qo/matchers/pattern_match.rb +2 -1
  40. data/lib/qo/public_api.rb +6 -5
  41. data/lib/qo/version.rb +1 -1
  42. data/performance_report.txt +73 -24
  43. data/qo.gemspec +2 -0
  44. metadata +61 -3
@@ -0,0 +1,867 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>
7
+ Module: Qo::PublicApi
8
+
9
+ &mdash; Documentation by YARD 0.9.12
10
+
11
+ </title>
12
+
13
+ <link rel="stylesheet" href="../css/style.css" type="text/css" charset="utf-8" />
14
+
15
+ <link rel="stylesheet" href="../css/common.css" type="text/css" charset="utf-8" />
16
+
17
+ <script type="text/javascript" charset="utf-8">
18
+ pathId = "Qo::PublicApi";
19
+ relpath = '../';
20
+ </script>
21
+
22
+
23
+ <script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
24
+
25
+ <script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
26
+
27
+
28
+ </head>
29
+ <body>
30
+ <div class="nav_wrap">
31
+ <iframe id="nav" src="../class_list.html?1"></iframe>
32
+ <div id="resizer"></div>
33
+ </div>
34
+
35
+ <div id="main" tabindex="-1">
36
+ <div id="header">
37
+ <div id="menu">
38
+
39
+ <a href="../_index.html">Index (P)</a> &raquo;
40
+ <span class='title'><span class='object_link'><a href="../Qo.html" title="Qo (module)">Qo</a></span></span>
41
+ &raquo;
42
+ <span class="title">PublicApi</span>
43
+
44
+ </div>
45
+
46
+ <div id="search">
47
+
48
+ <a class="full_list_link" id="class_list_link"
49
+ href="../class_list.html">
50
+
51
+ <svg width="24" height="24">
52
+ <rect x="0" y="4" width="24" height="4" rx="1" ry="1"></rect>
53
+ <rect x="0" y="12" width="24" height="4" rx="1" ry="1"></rect>
54
+ <rect x="0" y="20" width="24" height="4" rx="1" ry="1"></rect>
55
+ </svg>
56
+ </a>
57
+
58
+ </div>
59
+ <div class="clear"></div>
60
+ </div>
61
+
62
+ <div id="content"><h1>Module: Qo::PublicApi
63
+
64
+
65
+
66
+ </h1>
67
+ <div class="box_info">
68
+
69
+
70
+
71
+
72
+
73
+
74
+ <dl>
75
+ <dt>Includes:</dt>
76
+ <dd><span class='object_link'><a href="Exceptions.html" title="Qo::Exceptions (module)">Exceptions</a></span></dd>
77
+ </dl>
78
+
79
+
80
+
81
+
82
+ <dl>
83
+ <dt>Included in:</dt>
84
+ <dd><span class='object_link'><a href="../Qo.html" title="Qo (module)">Qo</a></span></dd>
85
+ </dl>
86
+
87
+
88
+
89
+ <dl>
90
+ <dt>Defined in:</dt>
91
+ <dd>lib/qo/public_api.rb</dd>
92
+ </dl>
93
+
94
+ </div>
95
+
96
+ <h2>Overview</h2><div class="docstring">
97
+ <div class="discussion">
98
+ <p>The Public API consists of methods that should be openly accessible to the
99
+ top level Qo namespace, and should not change. It should be used as the
100
+ subject of Acceptance level tests for the library and should not have its
101
+ externally facing methods renamed or moved under pain of a look of profound
102
+ disappointment from the creator.</p>
103
+
104
+
105
+ </div>
106
+ </div>
107
+ <div class="tags">
108
+
109
+ <p class="tag_title">Author:</p>
110
+ <ul class="author">
111
+
112
+ <li>
113
+
114
+
115
+
116
+
117
+
118
+ <div class='inline'><p>baweaver</p>
119
+ </div>
120
+
121
+ </li>
122
+
123
+ </ul>
124
+ <p class="tag_title">Since:</p>
125
+ <ul class="since">
126
+
127
+ <li>
128
+
129
+
130
+
131
+
132
+
133
+ <div class='inline'><p>0.2.0</p>
134
+ </div>
135
+
136
+ </li>
137
+
138
+ </ul>
139
+
140
+ </div>
141
+
142
+
143
+
144
+
145
+
146
+
147
+
148
+ <h2>
149
+ Instance Method Summary
150
+ <small><a href="#" class="summary_toggle">collapse</a></small>
151
+ </h2>
152
+
153
+ <ul class="summary">
154
+
155
+ <li class="public ">
156
+ <span class="summary_signature">
157
+
158
+ <a href="#and-instance_method" title="#and (instance method)">#<strong>and</strong>(*array_matchers, **keyword_matchers) &#x21d2; Proc[Any] </a>
159
+
160
+
161
+
162
+ (also: #[])
163
+
164
+ </span>
165
+
166
+
167
+
168
+
169
+
170
+
171
+
172
+
173
+
174
+ <span class="summary_desc"><div class='inline'><p>Creates an <code>and</code> type query matcher.</p>
175
+ </div></span>
176
+
177
+ </li>
178
+
179
+
180
+ <li class="public ">
181
+ <span class="summary_signature">
182
+
183
+ <a href="#match-instance_method" title="#match (instance method)">#<strong>match</strong>(*args) &#x21d2; Qo::PatternMatch | Any </a>
184
+
185
+
186
+
187
+ </span>
188
+
189
+
190
+
191
+
192
+
193
+
194
+
195
+
196
+
197
+ <span class="summary_desc"><div class='inline'><p>&quot;Curried&quot; function that waits for a target, or evaluates immediately if given one.</p>
198
+ </div></span>
199
+
200
+ </li>
201
+
202
+
203
+ <li class="public ">
204
+ <span class="summary_signature">
205
+
206
+ <a href="#matcher-instance_method" title="#matcher (instance method)">#<strong>matcher</strong>(*array_matchers, **keyword_matchers, &amp;fn) &#x21d2; Proc[Any] </a>
207
+
208
+
209
+
210
+ (also: #m)
211
+
212
+ </span>
213
+
214
+
215
+
216
+
217
+
218
+
219
+
220
+
221
+
222
+ <span class="summary_desc"><div class='inline'><p>Creates a Guard Block matcher.</p>
223
+ </div></span>
224
+
225
+ </li>
226
+
227
+
228
+ <li class="public ">
229
+ <span class="summary_signature">
230
+
231
+ <a href="#not-instance_method" title="#not (instance method)">#<strong>not</strong>(*array_matchers, **keyword_matchers) &#x21d2; Proc[Any] </a>
232
+
233
+
234
+
235
+ </span>
236
+
237
+
238
+
239
+
240
+
241
+
242
+
243
+
244
+
245
+ <span class="summary_desc"><div class='inline'><p>Creates a <code>not</code> type query matcher.</p>
246
+ </div></span>
247
+
248
+ </li>
249
+
250
+
251
+ <li class="public ">
252
+ <span class="summary_signature">
253
+
254
+ <a href="#or-instance_method" title="#or (instance method)">#<strong>or</strong>(*array_matchers, **keyword_matchers) &#x21d2; Proc[Any] </a>
255
+
256
+
257
+
258
+ </span>
259
+
260
+
261
+
262
+
263
+
264
+
265
+
266
+
267
+
268
+ <span class="summary_desc"><div class='inline'><p>Creates an <code>or</code> type query matcher.</p>
269
+ </div></span>
270
+
271
+ </li>
272
+
273
+
274
+ </ul>
275
+
276
+
277
+
278
+
279
+
280
+
281
+
282
+
283
+
284
+
285
+ <div id="instance_method_details" class="method_details_list">
286
+ <h2>Instance Method Details</h2>
287
+
288
+
289
+ <div class="method_details first">
290
+ <h3 class="signature first" id="and-instance_method">
291
+
292
+ #<strong>and</strong>(*array_matchers, **keyword_matchers) &#x21d2; <tt>Proc[Any]</tt>
293
+
294
+
295
+
296
+ <span class="aliases">Also known as:
297
+ <span class="names"><span id='[]-instance_method'>[]</span></span>
298
+ </span>
299
+
300
+
301
+
302
+ </h3><div class="docstring">
303
+ <div class="discussion">
304
+ <p>Creates an <code>and</code> type query matcher. All conditions in this type of matcher
305
+ must pass to be considered a &quot;match&quot;. It will short-circuit in the case of
306
+ a false match.</p>
307
+
308
+
309
+ </div>
310
+ </div>
311
+ <div class="tags">
312
+ <p class="tag_title">Parameters:</p>
313
+ <ul class="param">
314
+
315
+ <li>
316
+
317
+ <span class='name'>*array_matchers</span>
318
+
319
+
320
+ <span class='type'>(<tt>Array</tt>)</span>
321
+
322
+
323
+
324
+ &mdash;
325
+ <div class='inline'><p>Array-like conditionals</p>
326
+ </div>
327
+
328
+ </li>
329
+
330
+ <li>
331
+
332
+ <span class='name'>**keyword_matchers</span>
333
+
334
+
335
+ <span class='type'>(<tt>Hash</tt>)</span>
336
+
337
+
338
+
339
+ &mdash;
340
+ <div class='inline'><p>Keyword style conditionals</p>
341
+ </div>
342
+
343
+ </li>
344
+
345
+ </ul>
346
+
347
+ <p class="tag_title">Returns:</p>
348
+ <ul class="return">
349
+
350
+ <li>
351
+
352
+
353
+ <span class='type'>(<tt>Proc[Any]</tt>)</span>
354
+
355
+
356
+
357
+ &mdash;
358
+ <div class='inline'><p>Any -&gt; Bool # Given a target, will return if it &quot;matches&quot;</p>
359
+ </div>
360
+
361
+ </li>
362
+
363
+ </ul>
364
+ <p class="tag_title">Since:</p>
365
+ <ul class="since">
366
+
367
+ <li>
368
+
369
+
370
+
371
+
372
+
373
+ <div class='inline'><p>0.2.0</p>
374
+ </div>
375
+
376
+ </li>
377
+
378
+ </ul>
379
+
380
+ </div><table class="source_code">
381
+ <tr>
382
+ <td>
383
+ <pre class="lines">
384
+
385
+
386
+ 23
387
+ 24
388
+ 25</pre>
389
+ </td>
390
+ <td>
391
+ <pre class="code"><span class="info file"># File 'lib/qo/public_api.rb', line 23</span>
392
+
393
+ <span class='kw'>def</span> <span class='kw'>and</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_array_matchers'>array_matchers</span><span class='comma'>,</span> <span class='op'>**</span><span class='id identifier rubyid_keyword_matchers'>keyword_matchers</span><span class='rparen'>)</span>
394
+ <span class='id identifier rubyid_create_matcher'>create_matcher</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>and</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='op'>*</span><span class='id identifier rubyid_array_matchers'>array_matchers</span><span class='comma'>,</span> <span class='op'>**</span><span class='id identifier rubyid_keyword_matchers'>keyword_matchers</span><span class='rparen'>)</span>
395
+ <span class='kw'>end</span></pre>
396
+ </td>
397
+ </tr>
398
+ </table>
399
+ </div>
400
+
401
+ <div class="method_details ">
402
+ <h3 class="signature " id="match-instance_method">
403
+
404
+ #<strong>match</strong>(*args) &#x21d2; <tt>Qo::PatternMatch | Any</tt>
405
+
406
+
407
+
408
+
409
+
410
+ </h3><div class="docstring">
411
+ <div class="discussion">
412
+ <p>&quot;Curried&quot; function that waits for a target, or evaluates immediately if given
413
+ one.</p>
414
+
415
+ <p>A PatternMatch will try and run all GuardBlock matchers in sequence until
416
+ it finds one that &quot;matches&quot;. Once found, it will pass the target into the
417
+ associated matcher&#39;s block function.</p>
418
+
419
+
420
+ </div>
421
+ </div>
422
+ <div class="tags">
423
+ <p class="tag_title">Parameters:</p>
424
+ <ul class="param">
425
+
426
+ <li>
427
+
428
+ <span class='name'>*args</span>
429
+
430
+
431
+ <span class='type'>(<tt>Array[Any, *GuardBlockMatcher]</tt>)</span>
432
+
433
+
434
+
435
+ &mdash;
436
+ <div class='inline'><p>Collection of matchers to run, potentially prefixed by a target object</p>
437
+ </div>
438
+
439
+ </li>
440
+
441
+ </ul>
442
+
443
+ <p class="tag_title">Returns:</p>
444
+ <ul class="return">
445
+
446
+ <li>
447
+
448
+
449
+ <span class='type'>(<tt>Qo::PatternMatch | Any</tt>)</span>
450
+
451
+
452
+
453
+ &mdash;
454
+ <div class='inline'><p>Returns a PatternMatch waiting for a target, or an evaluated PatternMatch response</p>
455
+ </div>
456
+
457
+ </li>
458
+
459
+ </ul>
460
+ <p class="tag_title">Since:</p>
461
+ <ul class="since">
462
+
463
+ <li>
464
+
465
+
466
+
467
+
468
+
469
+ <div class='inline'><p>0.2.0</p>
470
+ </div>
471
+
472
+ </li>
473
+
474
+ </ul>
475
+
476
+ </div><table class="source_code">
477
+ <tr>
478
+ <td>
479
+ <pre class="lines">
480
+
481
+
482
+ 90
483
+ 91
484
+ 92
485
+ 93
486
+ 94
487
+ 95
488
+ 96
489
+ 97</pre>
490
+ </td>
491
+ <td>
492
+ <pre class="code"><span class="info file"># File 'lib/qo/public_api.rb', line 90</span>
493
+
494
+ <span class='kw'>def</span> <span class='id identifier rubyid_match'>match</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span>
495
+ <span class='kw'>if</span> <span class='id identifier rubyid_args'>args</span><span class='period'>.</span><span class='id identifier rubyid_first'>first</span><span class='period'>.</span><span class='id identifier rubyid_is_a?'>is_a?</span><span class='lparen'>(</span><span class='const'><span class='object_link'><a href="../Qo.html" title="Qo (module)">Qo</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="Matchers.html" title="Qo::Matchers (module)">Matchers</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="Matchers/GuardBlockMatcher.html" title="Qo::Matchers::GuardBlockMatcher (class)">GuardBlockMatcher</a></span></span><span class='rparen'>)</span>
496
+ <span class='const'><span class='object_link'><a href="../Qo.html" title="Qo (module)">Qo</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="Matchers.html" title="Qo::Matchers (module)">Matchers</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="Matchers/PatternMatch.html" title="Qo::Matchers::PatternMatch (class)">PatternMatch</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="Matchers/PatternMatch.html#initialize-instance_method" title="Qo::Matchers::PatternMatch#initialize (method)">new</a></span></span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span>
497
+ <span class='kw'>else</span>
498
+ <span class='id identifier rubyid_match_target'>match_target</span><span class='comma'>,</span> <span class='op'>*</span><span class='id identifier rubyid_qo_matchers'>qo_matchers</span> <span class='op'>=</span> <span class='id identifier rubyid_args'>args</span>
499
+ <span class='const'><span class='object_link'><a href="../Qo.html" title="Qo (module)">Qo</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="Matchers.html" title="Qo::Matchers (module)">Matchers</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="Matchers/PatternMatch.html" title="Qo::Matchers::PatternMatch (class)">PatternMatch</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="Matchers/PatternMatch.html#initialize-instance_method" title="Qo::Matchers::PatternMatch#initialize (method)">new</a></span></span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_qo_matchers'>qo_matchers</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_call'><span class='object_link'><a href="Matchers/PatternMatch.html#call-instance_method" title="Qo::Matchers::PatternMatch#call (method)">call</a></span></span><span class='lparen'>(</span><span class='id identifier rubyid_match_target'>match_target</span><span class='rparen'>)</span>
500
+ <span class='kw'>end</span>
501
+ <span class='kw'>end</span></pre>
502
+ </td>
503
+ </tr>
504
+ </table>
505
+ </div>
506
+
507
+ <div class="method_details ">
508
+ <h3 class="signature " id="matcher-instance_method">
509
+
510
+ #<strong>matcher</strong>(*array_matchers, **keyword_matchers, &amp;fn) &#x21d2; <tt>Proc[Any]</tt>
511
+
512
+
513
+
514
+ <span class="aliases">Also known as:
515
+ <span class="names"><span id='m-instance_method'>m</span></span>
516
+ </span>
517
+
518
+
519
+
520
+ </h3><div class="docstring">
521
+ <div class="discussion">
522
+ <p>Creates a Guard Block matcher.</p>
523
+
524
+ <p>A guard block matcher is used to guard a function from running unless
525
+ the left-hand matcher passes. Once called with a value, it will either
526
+ return <code>[false, false]</code> or <code>[true, Any]</code>.</p>
527
+
528
+ <p>This wrapping is done to preserve intended false or nil responses,
529
+ and is unwrapped with match below.</p>
530
+
531
+
532
+ </div>
533
+ </div>
534
+ <div class="tags">
535
+ <p class="tag_title">Parameters:</p>
536
+ <ul class="param">
537
+
538
+ <li>
539
+
540
+ <span class='name'>*array_matchers</span>
541
+
542
+
543
+ <span class='type'>(<tt>Array</tt>)</span>
544
+
545
+
546
+
547
+ &mdash;
548
+ <div class='inline'><p>varargs matchers</p>
549
+ </div>
550
+
551
+ </li>
552
+
553
+ <li>
554
+
555
+ <span class='name'>**keyword_matchers</span>
556
+
557
+
558
+ <span class='type'>(<tt>Hash</tt>)</span>
559
+
560
+
561
+
562
+ &mdash;
563
+ <div class='inline'><p>kwargs matchers</p>
564
+ </div>
565
+
566
+ </li>
567
+
568
+ <li>
569
+
570
+ <span class='name'>&amp;fn</span>
571
+
572
+
573
+ <span class='type'>(<tt>Proc</tt>)</span>
574
+
575
+
576
+
577
+ &mdash;
578
+ <div class='inline'><p>Guarded function</p>
579
+ </div>
580
+
581
+ </li>
582
+
583
+ </ul>
584
+
585
+ <p class="tag_title">Returns:</p>
586
+ <ul class="return">
587
+
588
+ <li>
589
+
590
+
591
+ <span class='type'>(<tt>Proc[Any]</tt>)</span>
592
+
593
+
594
+
595
+ &mdash;
596
+ <div class='inline'><p>Any -&gt; Proc[Any]</p>
597
+ </div>
598
+
599
+ </li>
600
+
601
+ </ul>
602
+ <p class="tag_title">Since:</p>
603
+ <ul class="since">
604
+
605
+ <li>
606
+
607
+
608
+
609
+
610
+
611
+ <div class='inline'><p>0.2.0</p>
612
+ </div>
613
+
614
+ </li>
615
+
616
+ </ul>
617
+
618
+ </div><table class="source_code">
619
+ <tr>
620
+ <td>
621
+ <pre class="lines">
622
+
623
+
624
+ 71
625
+ 72
626
+ 73</pre>
627
+ </td>
628
+ <td>
629
+ <pre class="code"><span class="info file"># File 'lib/qo/public_api.rb', line 71</span>
630
+
631
+ <span class='kw'>def</span> <span class='id identifier rubyid_matcher'>matcher</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_array_matchers'>array_matchers</span><span class='comma'>,</span> <span class='op'>**</span><span class='id identifier rubyid_keyword_matchers'>keyword_matchers</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_fn'>fn</span><span class='rparen'>)</span>
632
+ <span class='const'><span class='object_link'><a href="../Qo.html" title="Qo (module)">Qo</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="Matchers.html" title="Qo::Matchers (module)">Matchers</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="Matchers/GuardBlockMatcher.html" title="Qo::Matchers::GuardBlockMatcher (class)">GuardBlockMatcher</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="Matchers/GuardBlockMatcher.html#initialize-instance_method" title="Qo::Matchers::GuardBlockMatcher#initialize (method)">new</a></span></span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_array_matchers'>array_matchers</span><span class='comma'>,</span> <span class='op'>**</span><span class='id identifier rubyid_keyword_matchers'>keyword_matchers</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_fn'>fn</span><span class='rparen'>)</span>
633
+ <span class='kw'>end</span></pre>
634
+ </td>
635
+ </tr>
636
+ </table>
637
+ </div>
638
+
639
+ <div class="method_details ">
640
+ <h3 class="signature " id="not-instance_method">
641
+
642
+ #<strong>not</strong>(*array_matchers, **keyword_matchers) &#x21d2; <tt>Proc[Any]</tt>
643
+
644
+
645
+
646
+
647
+
648
+ </h3><div class="docstring">
649
+ <div class="discussion">
650
+ <p>Creates a <code>not</code> type query matcher. No conditions in this type of matcher
651
+ should pass to be considered a &quot;match&quot;. It will short-circuit in the case of
652
+ a true match.</p>
653
+
654
+
655
+ </div>
656
+ </div>
657
+ <div class="tags">
658
+ <p class="tag_title">Parameters:</p>
659
+ <ul class="param">
660
+
661
+ <li>
662
+
663
+ <span class='name'>*array_matchers</span>
664
+
665
+
666
+ <span class='type'>(<tt>Array</tt>)</span>
667
+
668
+
669
+
670
+ &mdash;
671
+ <div class='inline'><p>Array-like conditionals</p>
672
+ </div>
673
+
674
+ </li>
675
+
676
+ <li>
677
+
678
+ <span class='name'>**keyword_matchers</span>
679
+
680
+
681
+ <span class='type'>(<tt>Hash</tt>)</span>
682
+
683
+
684
+
685
+ &mdash;
686
+ <div class='inline'><p>Keyword style conditionals</p>
687
+ </div>
688
+
689
+ </li>
690
+
691
+ </ul>
692
+
693
+ <p class="tag_title">Returns:</p>
694
+ <ul class="return">
695
+
696
+ <li>
697
+
698
+
699
+ <span class='type'>(<tt>Proc[Any]</tt>)</span>
700
+
701
+
702
+
703
+ &mdash;
704
+ <div class='inline'><p>Any -&gt; Bool # Given a target, will return if it &quot;matches&quot;</p>
705
+ </div>
706
+
707
+ </li>
708
+
709
+ </ul>
710
+ <p class="tag_title">Since:</p>
711
+ <ul class="since">
712
+
713
+ <li>
714
+
715
+
716
+
717
+
718
+
719
+ <div class='inline'><p>0.2.0</p>
720
+ </div>
721
+
722
+ </li>
723
+
724
+ </ul>
725
+
726
+ </div><table class="source_code">
727
+ <tr>
728
+ <td>
729
+ <pre class="lines">
730
+
731
+
732
+ 52
733
+ 53
734
+ 54</pre>
735
+ </td>
736
+ <td>
737
+ <pre class="code"><span class="info file"># File 'lib/qo/public_api.rb', line 52</span>
738
+
739
+ <span class='kw'>def</span> <span class='kw'>not</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_array_matchers'>array_matchers</span><span class='comma'>,</span> <span class='op'>**</span><span class='id identifier rubyid_keyword_matchers'>keyword_matchers</span><span class='rparen'>)</span>
740
+ <span class='id identifier rubyid_create_matcher'>create_matcher</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>not</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='op'>*</span><span class='id identifier rubyid_array_matchers'>array_matchers</span><span class='comma'>,</span> <span class='op'>**</span><span class='id identifier rubyid_keyword_matchers'>keyword_matchers</span><span class='rparen'>)</span>
741
+ <span class='kw'>end</span></pre>
742
+ </td>
743
+ </tr>
744
+ </table>
745
+ </div>
746
+
747
+ <div class="method_details ">
748
+ <h3 class="signature " id="or-instance_method">
749
+
750
+ #<strong>or</strong>(*array_matchers, **keyword_matchers) &#x21d2; <tt>Proc[Any]</tt>
751
+
752
+
753
+
754
+
755
+
756
+ </h3><div class="docstring">
757
+ <div class="discussion">
758
+ <p>Creates an <code>or</code> type query matcher. Any conditions in this type of matcher
759
+ must pass to be considered a &quot;match&quot;. It will short-circuit in the case of
760
+ a true match.</p>
761
+
762
+
763
+ </div>
764
+ </div>
765
+ <div class="tags">
766
+ <p class="tag_title">Parameters:</p>
767
+ <ul class="param">
768
+
769
+ <li>
770
+
771
+ <span class='name'>*array_matchers</span>
772
+
773
+
774
+ <span class='type'>(<tt>Array</tt>)</span>
775
+
776
+
777
+
778
+ &mdash;
779
+ <div class='inline'><p>Array-like conditionals</p>
780
+ </div>
781
+
782
+ </li>
783
+
784
+ <li>
785
+
786
+ <span class='name'>**keyword_matchers</span>
787
+
788
+
789
+ <span class='type'>(<tt>Hash</tt>)</span>
790
+
791
+
792
+
793
+ &mdash;
794
+ <div class='inline'><p>Keyword style conditionals</p>
795
+ </div>
796
+
797
+ </li>
798
+
799
+ </ul>
800
+
801
+ <p class="tag_title">Returns:</p>
802
+ <ul class="return">
803
+
804
+ <li>
805
+
806
+
807
+ <span class='type'>(<tt>Proc[Any]</tt>)</span>
808
+
809
+
810
+
811
+ &mdash;
812
+ <div class='inline'><p>Any -&gt; Bool # Given a target, will return if it &quot;matches&quot;</p>
813
+ </div>
814
+
815
+ </li>
816
+
817
+ </ul>
818
+ <p class="tag_title">Since:</p>
819
+ <ul class="since">
820
+
821
+ <li>
822
+
823
+
824
+
825
+
826
+
827
+ <div class='inline'><p>0.2.0</p>
828
+ </div>
829
+
830
+ </li>
831
+
832
+ </ul>
833
+
834
+ </div><table class="source_code">
835
+ <tr>
836
+ <td>
837
+ <pre class="lines">
838
+
839
+
840
+ 39
841
+ 40
842
+ 41</pre>
843
+ </td>
844
+ <td>
845
+ <pre class="code"><span class="info file"># File 'lib/qo/public_api.rb', line 39</span>
846
+
847
+ <span class='kw'>def</span> <span class='kw'>or</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_array_matchers'>array_matchers</span><span class='comma'>,</span> <span class='op'>**</span><span class='id identifier rubyid_keyword_matchers'>keyword_matchers</span><span class='rparen'>)</span>
848
+ <span class='id identifier rubyid_create_matcher'>create_matcher</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>or</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='op'>*</span><span class='id identifier rubyid_array_matchers'>array_matchers</span><span class='comma'>,</span> <span class='op'>**</span><span class='id identifier rubyid_keyword_matchers'>keyword_matchers</span><span class='rparen'>)</span>
849
+ <span class='kw'>end</span></pre>
850
+ </td>
851
+ </tr>
852
+ </table>
853
+ </div>
854
+
855
+ </div>
856
+
857
+ </div>
858
+
859
+ <div id="footer">
860
+ Generated on Sun Apr 15 20:29:44 2018 by
861
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
862
+ 0.9.12 (ruby-2.4.4).
863
+ </div>
864
+
865
+ </div>
866
+ </body>
867
+ </html>