puppeteer-ruby 0.0.4 → 0.0.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (110) hide show
  1. checksums.yaml +4 -4
  2. data/.circleci/config.yml +30 -0
  3. data/.rubocop.yml +4 -5
  4. data/docs/Puppeteer.html +2010 -0
  5. data/docs/Puppeteer/AsyncAwaitBehavior.html +105 -0
  6. data/docs/Puppeteer/Browser.html +2150 -0
  7. data/docs/Puppeteer/BrowserContext.html +809 -0
  8. data/docs/Puppeteer/BrowserFetcher.html +214 -0
  9. data/docs/Puppeteer/BrowserRunner.html +914 -0
  10. data/docs/Puppeteer/BrowserRunner/BrowserProcess.html +477 -0
  11. data/docs/Puppeteer/CDPSession.html +784 -0
  12. data/docs/Puppeteer/CDPSession/Error.html +124 -0
  13. data/docs/Puppeteer/ConcurrentRubyUtils.html +430 -0
  14. data/docs/Puppeteer/Connection.html +960 -0
  15. data/docs/Puppeteer/Connection/MessageCallback.html +434 -0
  16. data/docs/Puppeteer/Connection/ProtocolError.html +216 -0
  17. data/docs/Puppeteer/Connection/RequestDebugPrinter.html +217 -0
  18. data/docs/Puppeteer/Connection/ResponseDebugPrinter.html +244 -0
  19. data/docs/Puppeteer/ConsoleMessage.html +565 -0
  20. data/docs/Puppeteer/ConsoleMessage/Location.html +433 -0
  21. data/docs/Puppeteer/DOMWorld.html +1580 -0
  22. data/docs/Puppeteer/DOMWorld/DetachedError.html +124 -0
  23. data/docs/Puppeteer/DOMWorld/DocumentEvaluationError.html +124 -0
  24. data/docs/Puppeteer/DebugPrint.html +233 -0
  25. data/docs/Puppeteer/Device.html +470 -0
  26. data/docs/Puppeteer/Devices.html +139 -0
  27. data/docs/Puppeteer/ElementHandle.html +1603 -0
  28. data/docs/Puppeteer/ElementHandle/ElementNotFoundError.html +206 -0
  29. data/docs/Puppeteer/ElementHandle/ElementNotVisibleError.html +206 -0
  30. data/docs/Puppeteer/ElementHandle/Point.html +481 -0
  31. data/docs/Puppeteer/ElementHandle/ScrollIntoViewError.html +124 -0
  32. data/docs/Puppeteer/EmulationManager.html +454 -0
  33. data/docs/Puppeteer/EventCallbackable.html +433 -0
  34. data/docs/Puppeteer/EventCallbackable/EventListeners.html +435 -0
  35. data/docs/Puppeteer/ExecutionContext.html +772 -0
  36. data/docs/Puppeteer/ExecutionContext/EvaluationError.html +124 -0
  37. data/docs/Puppeteer/ExecutionContext/JavaScriptExpression.html +357 -0
  38. data/docs/Puppeteer/ExecutionContext/JavaScriptFunction.html +389 -0
  39. data/docs/Puppeteer/Frame.html +3625 -0
  40. data/docs/Puppeteer/FrameManager.html +2414 -0
  41. data/docs/Puppeteer/FrameManager/NavigationError.html +124 -0
  42. data/docs/Puppeteer/IfPresent.html +222 -0
  43. data/docs/Puppeteer/JSHandle.html +1352 -0
  44. data/docs/Puppeteer/Keyboard.html +1557 -0
  45. data/docs/Puppeteer/Keyboard/KeyDefinition.html +831 -0
  46. data/docs/Puppeteer/Keyboard/KeyDescription.html +603 -0
  47. data/docs/Puppeteer/Launcher.html +237 -0
  48. data/docs/Puppeteer/Launcher/Base.html +385 -0
  49. data/docs/Puppeteer/Launcher/Base/ExecutablePathNotFound.html +124 -0
  50. data/docs/Puppeteer/Launcher/BrowserOptions.html +441 -0
  51. data/docs/Puppeteer/Launcher/Chrome.html +628 -0
  52. data/docs/Puppeteer/Launcher/Chrome/DefaultArgs.html +382 -0
  53. data/docs/Puppeteer/Launcher/ChromeArgOptions.html +531 -0
  54. data/docs/Puppeteer/Launcher/LaunchOptions.html +893 -0
  55. data/docs/Puppeteer/LifecycleWatcher.html +834 -0
  56. data/docs/Puppeteer/LifecycleWatcher/ExpectedLifecycle.html +363 -0
  57. data/docs/Puppeteer/LifecycleWatcher/FrameDetachedError.html +206 -0
  58. data/docs/Puppeteer/LifecycleWatcher/TerminatedError.html +124 -0
  59. data/docs/Puppeteer/Mouse.html +1105 -0
  60. data/docs/Puppeteer/Mouse/Button.html +136 -0
  61. data/docs/Puppeteer/NetworkManager.html +901 -0
  62. data/docs/Puppeteer/NetworkManager/Credentials.html +385 -0
  63. data/docs/Puppeteer/Page.html +5426 -0
  64. data/docs/Puppeteer/Page/ScreenshotOptions.html +845 -0
  65. data/docs/Puppeteer/Page/ScriptTag.html +555 -0
  66. data/docs/Puppeteer/Page/StyleTag.html +448 -0
  67. data/docs/Puppeteer/Page/TargetCrashedError.html +124 -0
  68. data/docs/Puppeteer/RemoteObject.html +951 -0
  69. data/docs/Puppeteer/Target.html +1384 -0
  70. data/docs/Puppeteer/Target/InitializeFailure.html +124 -0
  71. data/docs/Puppeteer/Target/TargetInfo.html +729 -0
  72. data/docs/Puppeteer/TimeoutError.html +135 -0
  73. data/docs/Puppeteer/TimeoutSettings.html +496 -0
  74. data/docs/Puppeteer/TouchScreen.html +464 -0
  75. data/docs/Puppeteer/Viewport.html +757 -0
  76. data/docs/Puppeteer/WaitTask.html +211 -0
  77. data/docs/Puppeteer/WaitTask/TerminatedError.html +124 -0
  78. data/docs/Puppeteer/WebSocket.html +673 -0
  79. data/docs/Puppeteer/WebSocket/DriverImpl.html +412 -0
  80. data/docs/Puppeteer/WebSocketTransport.html +600 -0
  81. data/docs/Puppeteer/WebSocktTransportError.html +124 -0
  82. data/docs/_index.html +788 -0
  83. data/docs/class_list.html +51 -0
  84. data/docs/css/common.css +1 -0
  85. data/docs/css/full_list.css +58 -0
  86. data/docs/css/style.css +496 -0
  87. data/docs/file.README.html +121 -0
  88. data/docs/file_list.html +56 -0
  89. data/docs/frames.html +17 -0
  90. data/docs/index.html +121 -0
  91. data/docs/js/app.js +314 -0
  92. data/docs/js/full_list.js +216 -0
  93. data/docs/js/jquery.js +4 -0
  94. data/docs/method_list.html +3747 -0
  95. data/docs/top-level-namespace.html +126 -0
  96. data/lib/puppeteer.rb +9 -7
  97. data/lib/puppeteer/async_await_behavior.rb +6 -0
  98. data/lib/puppeteer/browser.rb +21 -1
  99. data/lib/puppeteer/connection.rb +1 -1
  100. data/lib/puppeteer/dom_world.rb +15 -2
  101. data/lib/puppeteer/element_handle.rb +3 -2
  102. data/lib/puppeteer/frame.rb +4 -0
  103. data/lib/puppeteer/frame_manager.rb +1 -1
  104. data/lib/puppeteer/js_handle.rb +3 -2
  105. data/lib/puppeteer/launcher.rb +0 -1
  106. data/lib/puppeteer/lifecycle_watcher.rb +3 -3
  107. data/lib/puppeteer/page.rb +6 -4
  108. data/lib/puppeteer/version.rb +1 -1
  109. data/puppeteer-ruby.gemspec +4 -1
  110. metadata +138 -4
@@ -0,0 +1,2414 @@
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
+ Class: Puppeteer::FrameManager
8
+
9
+ &mdash; Documentation by YARD 0.9.24
10
+
11
+ </title>
12
+
13
+ <link rel="stylesheet" href="../css/style.css" type="text/css" />
14
+
15
+ <link rel="stylesheet" href="../css/common.css" type="text/css" />
16
+
17
+ <script type="text/javascript">
18
+ pathId = "Puppeteer::FrameManager";
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 (F)</a> &raquo;
40
+ <span class='title'><span class='object_link'><a href="../Puppeteer.html" title="Puppeteer (class)">Puppeteer</a></span></span>
41
+ &raquo;
42
+ <span class="title">FrameManager</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>Class: Puppeteer::FrameManager
63
+
64
+
65
+
66
+ </h1>
67
+ <div class="box_info">
68
+
69
+ <dl>
70
+ <dt>Inherits:</dt>
71
+ <dd>
72
+ <span class="inheritName">Object</span>
73
+
74
+ <ul class="fullTree">
75
+ <li>Object</li>
76
+
77
+ <li class="next">Puppeteer::FrameManager</li>
78
+
79
+ </ul>
80
+ <a href="#" class="inheritanceTree">show all</a>
81
+
82
+ </dd>
83
+ </dl>
84
+
85
+
86
+
87
+
88
+
89
+
90
+ <dl>
91
+ <dt>Includes:</dt>
92
+ <dd><span class='object_link'><a href="DebugPrint.html" title="Puppeteer::DebugPrint (module)">DebugPrint</a></span>, <span class='object_link'><a href="EventCallbackable.html" title="Puppeteer::EventCallbackable (module)">EventCallbackable</a></span>, <span class='object_link'><a href="IfPresent.html" title="Puppeteer::IfPresent (module)">IfPresent</a></span></dd>
93
+ </dl>
94
+
95
+
96
+
97
+
98
+
99
+
100
+ <dl>
101
+ <dt>Defined in:</dt>
102
+ <dd>lib/puppeteer/frame_manager.rb</dd>
103
+ </dl>
104
+
105
+ </div>
106
+
107
+ <h2>Defined Under Namespace</h2>
108
+ <p class="children">
109
+
110
+
111
+
112
+
113
+ <strong class="classes">Classes:</strong> <span class='object_link'><a href="FrameManager/NavigationError.html" title="Puppeteer::FrameManager::NavigationError (class)">NavigationError</a></span>
114
+
115
+
116
+ </p>
117
+
118
+
119
+ <h2>
120
+ Constant Summary
121
+ <small><a href="#" class="constants_summary_toggle">collapse</a></small>
122
+ </h2>
123
+
124
+ <dl class="constants">
125
+
126
+ <dt id="UTILITY_WORLD_NAME-constant" class="">UTILITY_WORLD_NAME =
127
+
128
+ </dt>
129
+ <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>__puppeteer_utility_world__</span><span class='tstring_end'>&#39;</span></span></pre></dd>
130
+
131
+ </dl>
132
+
133
+
134
+
135
+
136
+
137
+ <h2>Instance Attribute Summary <small><a href="#" class="summary_toggle">collapse</a></small></h2>
138
+ <ul class="summary">
139
+
140
+ <li class="public ">
141
+ <span class="summary_signature">
142
+
143
+ <a href="#client-instance_method" title="#client (instance method)">#<strong>client</strong> &#x21d2; Object </a>
144
+
145
+
146
+
147
+ </span>
148
+
149
+
150
+
151
+
152
+ <span class="note title readonly">readonly</span>
153
+
154
+
155
+
156
+
157
+
158
+
159
+
160
+
161
+
162
+ <span class="summary_desc"><div class='inline'>
163
+ <p>Returns the value of attribute client.</p>
164
+ </div></span>
165
+
166
+ </li>
167
+
168
+
169
+ <li class="public ">
170
+ <span class="summary_signature">
171
+
172
+ <a href="#network_manager-instance_method" title="#network_manager (instance method)">#<strong>network_manager</strong> &#x21d2; Object </a>
173
+
174
+
175
+
176
+ </span>
177
+
178
+
179
+
180
+
181
+ <span class="note title readonly">readonly</span>
182
+
183
+
184
+
185
+
186
+
187
+
188
+
189
+
190
+
191
+ <span class="summary_desc"><div class='inline'>
192
+ <p>Returns the value of attribute network_manager.</p>
193
+ </div></span>
194
+
195
+ </li>
196
+
197
+
198
+ <li class="public ">
199
+ <span class="summary_signature">
200
+
201
+ <a href="#timeout_settings-instance_method" title="#timeout_settings (instance method)">#<strong>timeout_settings</strong> &#x21d2; Object </a>
202
+
203
+
204
+
205
+ </span>
206
+
207
+
208
+
209
+
210
+ <span class="note title readonly">readonly</span>
211
+
212
+
213
+
214
+
215
+
216
+
217
+
218
+
219
+
220
+ <span class="summary_desc"><div class='inline'>
221
+ <p>Returns the value of attribute timeout_settings.</p>
222
+ </div></span>
223
+
224
+ </li>
225
+
226
+
227
+ </ul>
228
+
229
+
230
+
231
+
232
+
233
+ <h2>
234
+ Instance Method Summary
235
+ <small><a href="#" class="summary_toggle">collapse</a></small>
236
+ </h2>
237
+
238
+ <ul class="summary">
239
+
240
+ <li class="public ">
241
+ <span class="summary_signature">
242
+
243
+ <a href="#ensure_isolated_world-instance_method" title="#ensure_isolated_world (instance method)">#<strong>ensure_isolated_world</strong>(name) &#x21d2; Object </a>
244
+
245
+
246
+
247
+ </span>
248
+
249
+
250
+
251
+
252
+
253
+
254
+
255
+
256
+
257
+ <span class="summary_desc"><div class='inline'></div></span>
258
+
259
+ </li>
260
+
261
+
262
+ <li class="public ">
263
+ <span class="summary_signature">
264
+
265
+ <a href="#execution_context_by_id-instance_method" title="#execution_context_by_id (instance method)">#<strong>execution_context_by_id</strong>(context_id) &#x21d2; Object </a>
266
+
267
+
268
+
269
+ </span>
270
+
271
+
272
+
273
+
274
+
275
+
276
+
277
+
278
+
279
+ <span class="summary_desc"><div class='inline'></div></span>
280
+
281
+ </li>
282
+
283
+
284
+ <li class="public ">
285
+ <span class="summary_signature">
286
+
287
+ <a href="#frame-instance_method" title="#frame (instance method)">#<strong>frame</strong>(frame_id) &#x21d2; ?Frame </a>
288
+
289
+
290
+
291
+ </span>
292
+
293
+
294
+
295
+
296
+
297
+
298
+
299
+
300
+
301
+ <span class="summary_desc"><div class='inline'></div></span>
302
+
303
+ </li>
304
+
305
+
306
+ <li class="public ">
307
+ <span class="summary_signature">
308
+
309
+ <a href="#frames-instance_method" title="#frames (instance method)">#<strong>frames</strong> &#x21d2; !Array&lt;!Frame&gt; </a>
310
+
311
+
312
+
313
+ </span>
314
+
315
+
316
+
317
+
318
+
319
+
320
+
321
+
322
+
323
+ <span class="summary_desc"><div class='inline'></div></span>
324
+
325
+ </li>
326
+
327
+
328
+ <li class="public ">
329
+ <span class="summary_signature">
330
+
331
+ <a href="#handle_execution_context_created-instance_method" title="#handle_execution_context_created (instance method)">#<strong>handle_execution_context_created</strong>(context_payload) &#x21d2; Object </a>
332
+
333
+
334
+
335
+ </span>
336
+
337
+
338
+
339
+
340
+
341
+
342
+
343
+
344
+
345
+ <span class="summary_desc"><div class='inline'></div></span>
346
+
347
+ </li>
348
+
349
+
350
+ <li class="public ">
351
+ <span class="summary_signature">
352
+
353
+ <a href="#handle_execution_context_destroyed-instance_method" title="#handle_execution_context_destroyed (instance method)">#<strong>handle_execution_context_destroyed</strong>(execution_context_id) &#x21d2; Object </a>
354
+
355
+
356
+
357
+ </span>
358
+
359
+
360
+
361
+
362
+
363
+
364
+
365
+
366
+
367
+ <span class="summary_desc"><div class='inline'></div></span>
368
+
369
+ </li>
370
+
371
+
372
+ <li class="public ">
373
+ <span class="summary_signature">
374
+
375
+ <a href="#handle_execution_contexts_cleared-instance_method" title="#handle_execution_contexts_cleared (instance method)">#<strong>handle_execution_contexts_cleared</strong> &#x21d2; Object </a>
376
+
377
+
378
+
379
+ </span>
380
+
381
+
382
+
383
+
384
+
385
+
386
+
387
+
388
+
389
+ <span class="summary_desc"><div class='inline'></div></span>
390
+
391
+ </li>
392
+
393
+
394
+ <li class="public ">
395
+ <span class="summary_signature">
396
+
397
+ <a href="#handle_frame_attached-instance_method" title="#handle_frame_attached (instance method)">#<strong>handle_frame_attached</strong>(frame_id, parent_frame_id) &#x21d2; Object </a>
398
+
399
+
400
+
401
+ </span>
402
+
403
+
404
+
405
+
406
+
407
+
408
+
409
+
410
+
411
+ <span class="summary_desc"><div class='inline'></div></span>
412
+
413
+ </li>
414
+
415
+
416
+ <li class="public ">
417
+ <span class="summary_signature">
418
+
419
+ <a href="#handle_frame_detached-instance_method" title="#handle_frame_detached (instance method)">#<strong>handle_frame_detached</strong>(frame_id) &#x21d2; Object </a>
420
+
421
+
422
+
423
+ </span>
424
+
425
+
426
+
427
+
428
+
429
+
430
+
431
+
432
+
433
+ <span class="summary_desc"><div class='inline'></div></span>
434
+
435
+ </li>
436
+
437
+
438
+ <li class="public ">
439
+ <span class="summary_signature">
440
+
441
+ <a href="#handle_frame_navigated-instance_method" title="#handle_frame_navigated (instance method)">#<strong>handle_frame_navigated</strong>(frame_payload) &#x21d2; Object </a>
442
+
443
+
444
+
445
+ </span>
446
+
447
+
448
+
449
+
450
+
451
+
452
+
453
+
454
+
455
+ <span class="summary_desc"><div class='inline'></div></span>
456
+
457
+ </li>
458
+
459
+
460
+ <li class="public ">
461
+ <span class="summary_signature">
462
+
463
+ <a href="#handle_frame_navigated_within_document-instance_method" title="#handle_frame_navigated_within_document (instance method)">#<strong>handle_frame_navigated_within_document</strong>(frame_id, url) &#x21d2; Object </a>
464
+
465
+
466
+
467
+ </span>
468
+
469
+
470
+
471
+
472
+
473
+
474
+
475
+
476
+
477
+ <span class="summary_desc"><div class='inline'></div></span>
478
+
479
+ </li>
480
+
481
+
482
+ <li class="public ">
483
+ <span class="summary_signature">
484
+
485
+ <a href="#handle_frame_stopped_loading-instance_method" title="#handle_frame_stopped_loading (instance method)">#<strong>handle_frame_stopped_loading</strong>(frame_id) &#x21d2; Object </a>
486
+
487
+
488
+
489
+ </span>
490
+
491
+
492
+
493
+
494
+
495
+
496
+
497
+
498
+
499
+ <span class="summary_desc"><div class='inline'></div></span>
500
+
501
+ </li>
502
+
503
+
504
+ <li class="public ">
505
+ <span class="summary_signature">
506
+
507
+ <a href="#handle_frame_tree-instance_method" title="#handle_frame_tree (instance method)">#<strong>handle_frame_tree</strong>(frame_tree) &#x21d2; Object </a>
508
+
509
+
510
+
511
+ </span>
512
+
513
+
514
+
515
+
516
+
517
+
518
+
519
+
520
+
521
+ <span class="summary_desc"><div class='inline'></div></span>
522
+
523
+ </li>
524
+
525
+
526
+ <li class="public ">
527
+ <span class="summary_signature">
528
+
529
+ <a href="#handle_lifecycle_event-instance_method" title="#handle_lifecycle_event (instance method)">#<strong>handle_lifecycle_event</strong>(event) &#x21d2; Object </a>
530
+
531
+
532
+
533
+ </span>
534
+
535
+
536
+
537
+
538
+
539
+
540
+
541
+
542
+
543
+ <span class="summary_desc"><div class='inline'></div></span>
544
+
545
+ </li>
546
+
547
+
548
+ <li class="public ">
549
+ <span class="summary_signature">
550
+
551
+ <a href="#initialize-instance_method" title="#initialize (instance method)">#<strong>initialize</strong>(client, page, ignore_https_errors, timeout_settings) &#x21d2; FrameManager </a>
552
+
553
+
554
+
555
+ </span>
556
+
557
+
558
+ <span class="note title constructor">constructor</span>
559
+
560
+
561
+
562
+
563
+
564
+
565
+
566
+
567
+ <span class="summary_desc"><div class='inline'>
568
+ <p>A new instance of FrameManager.</p>
569
+ </div></span>
570
+
571
+ </li>
572
+
573
+
574
+ <li class="public ">
575
+ <span class="summary_signature">
576
+
577
+ <a href="#main_frame-instance_method" title="#main_frame (instance method)">#<strong>main_frame</strong> &#x21d2; !Frame </a>
578
+
579
+
580
+
581
+ </span>
582
+
583
+
584
+
585
+
586
+
587
+
588
+
589
+
590
+
591
+ <span class="summary_desc"><div class='inline'></div></span>
592
+
593
+ </li>
594
+
595
+
596
+ <li class="public ">
597
+ <span class="summary_signature">
598
+
599
+ <a href="#navigate_frame-instance_method" title="#navigate_frame (instance method)">#<strong>navigate_frame</strong>(frame, url, referer: nil, timeout: nil, wait_until: nil) &#x21d2; Puppeteer::Response </a>
600
+
601
+
602
+
603
+ </span>
604
+
605
+
606
+
607
+
608
+
609
+
610
+
611
+
612
+
613
+ <span class="summary_desc"><div class='inline'></div></span>
614
+
615
+ </li>
616
+
617
+
618
+ <li class="public ">
619
+ <span class="summary_signature">
620
+
621
+ <a href="#page-instance_method" title="#page (instance method)">#<strong>page</strong> &#x21d2; !Puppeteer.Page </a>
622
+
623
+
624
+
625
+ </span>
626
+
627
+
628
+
629
+
630
+
631
+
632
+
633
+
634
+
635
+ <span class="summary_desc"><div class='inline'></div></span>
636
+
637
+ </li>
638
+
639
+
640
+ <li class="public ">
641
+ <span class="summary_signature">
642
+
643
+ <a href="#wait_for_frame_navigation-instance_method" title="#wait_for_frame_navigation (instance method)">#<strong>wait_for_frame_navigation</strong>(frame, timeout: nil, wait_until: nil) &#x21d2; Puppeteer::Response </a>
644
+
645
+
646
+
647
+ </span>
648
+
649
+
650
+
651
+
652
+
653
+
654
+
655
+
656
+
657
+ <span class="summary_desc"><div class='inline'></div></span>
658
+
659
+ </li>
660
+
661
+
662
+ </ul>
663
+
664
+
665
+
666
+
667
+
668
+
669
+
670
+
671
+
672
+
673
+
674
+ <h3 class="inherited">Methods included from <span class='object_link'><a href="EventCallbackable.html" title="Puppeteer::EventCallbackable (module)">EventCallbackable</a></span></h3>
675
+ <p class="inherited"><span class='object_link'><a href="EventCallbackable.html#add_event_listener-instance_method" title="Puppeteer::EventCallbackable#add_event_listener (method)">#add_event_listener</a></span>, <span class='object_link'><a href="EventCallbackable.html#emit_event-instance_method" title="Puppeteer::EventCallbackable#emit_event (method)">#emit_event</a></span>, <span class='object_link'><a href="EventCallbackable.html#on_event-instance_method" title="Puppeteer::EventCallbackable#on_event (method)">#on_event</a></span>, <span class='object_link'><a href="EventCallbackable.html#remove_event_listener-instance_method" title="Puppeteer::EventCallbackable#remove_event_listener (method)">#remove_event_listener</a></span></p>
676
+
677
+
678
+
679
+
680
+
681
+
682
+
683
+
684
+
685
+ <h3 class="inherited">Methods included from <span class='object_link'><a href="IfPresent.html" title="Puppeteer::IfPresent (module)">IfPresent</a></span></h3>
686
+ <p class="inherited"><span class='object_link'><a href="IfPresent.html#if_present-instance_method" title="Puppeteer::IfPresent#if_present (method)">#if_present</a></span></p>
687
+
688
+
689
+
690
+
691
+
692
+
693
+
694
+
695
+
696
+ <h3 class="inherited">Methods included from <span class='object_link'><a href="DebugPrint.html" title="Puppeteer::DebugPrint (module)">DebugPrint</a></span></h3>
697
+ <p class="inherited"><span class='object_link'><a href="DebugPrint.html#debug_print-instance_method" title="Puppeteer::DebugPrint#debug_print (method)">#debug_print</a></span>, <span class='object_link'><a href="DebugPrint.html#debug_puts-instance_method" title="Puppeteer::DebugPrint#debug_puts (method)">#debug_puts</a></span></p>
698
+ <div id="constructor_details" class="method_details_list">
699
+ <h2>Constructor Details</h2>
700
+
701
+ <div class="method_details first">
702
+ <h3 class="signature first" id="initialize-instance_method">
703
+
704
+ #<strong>initialize</strong>(client, page, ignore_https_errors, timeout_settings) &#x21d2; <tt><span class='object_link'><a href="" title="Puppeteer::FrameManager (class)">FrameManager</a></span></tt>
705
+
706
+
707
+
708
+
709
+
710
+ </h3><div class="docstring">
711
+ <div class="discussion">
712
+
713
+ <p>Returns a new instance of FrameManager.</p>
714
+
715
+
716
+ </div>
717
+ </div>
718
+ <div class="tags">
719
+ <p class="tag_title">Parameters:</p>
720
+ <ul class="param">
721
+
722
+ <li>
723
+
724
+ <span class='name'>client</span>
725
+
726
+
727
+ <span class='type'>(<tt>!<span class='object_link'><a href="../Puppeteer.html" title="Puppeteer (class)">Puppeteer</a></span>.<span class='object_link'><a href="CDPSession.html" title="Puppeteer::CDPSession (class)">CDPSession</a></span></tt>)</span>
728
+
729
+
730
+
731
+ </li>
732
+
733
+ <li>
734
+
735
+ <span class='name'>page</span>
736
+
737
+
738
+ <span class='type'>(<tt>!<span class='object_link'><a href="../Puppeteer.html" title="Puppeteer (class)">Puppeteer</a></span>.<span class='object_link'><a href="Page.html" title="Puppeteer::Page (class)">Page</a></span></tt>)</span>
739
+
740
+
741
+
742
+ </li>
743
+
744
+ <li>
745
+
746
+ <span class='name'>ignoreHTTPSErrors</span>
747
+
748
+
749
+ <span class='type'>(<tt>boolean</tt>)</span>
750
+
751
+
752
+
753
+ </li>
754
+
755
+ <li>
756
+
757
+ <span class='name'>timeoutSettings</span>
758
+
759
+
760
+ <span class='type'>(<tt>!<span class='object_link'><a href="../Puppeteer.html" title="Puppeteer (class)">Puppeteer</a></span>.<span class='object_link'><a href="TimeoutSettings.html" title="Puppeteer::TimeoutSettings (class)">TimeoutSettings</a></span></tt>)</span>
761
+
762
+
763
+
764
+ </li>
765
+
766
+ </ul>
767
+
768
+
769
+ </div><table class="source_code">
770
+ <tr>
771
+ <td>
772
+ <pre class="lines">
773
+
774
+
775
+ 15
776
+ 16
777
+ 17
778
+ 18
779
+ 19
780
+ 20
781
+ 21
782
+ 22
783
+ 23
784
+ 24
785
+ 25
786
+ 26
787
+ 27
788
+ 28
789
+ 29
790
+ 30
791
+ 31
792
+ 32
793
+ 33
794
+ 34
795
+ 35
796
+ 36
797
+ 37
798
+ 38
799
+ 39
800
+ 40
801
+ 41
802
+ 42
803
+ 43
804
+ 44
805
+ 45
806
+ 46
807
+ 47
808
+ 48
809
+ 49
810
+ 50
811
+ 51
812
+ 52
813
+ 53
814
+ 54
815
+ 55
816
+ 56
817
+ 57
818
+ 58</pre>
819
+ </td>
820
+ <td>
821
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 15</span>
822
+
823
+ <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_page'>page</span><span class='comma'>,</span> <span class='id identifier rubyid_ignore_https_errors'>ignore_https_errors</span><span class='comma'>,</span> <span class='id identifier rubyid_timeout_settings'>timeout_settings</span><span class='rparen'>)</span>
824
+ <span class='ivar'>@client</span> <span class='op'>=</span> <span class='id identifier rubyid_client'>client</span>
825
+ <span class='ivar'>@page</span> <span class='op'>=</span> <span class='id identifier rubyid_page'>page</span>
826
+ <span class='ivar'>@network_manager</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="../Puppeteer.html" title="Puppeteer (class)">Puppeteer</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="NetworkManager.html" title="Puppeteer::NetworkManager (class)">NetworkManager</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="NetworkManager.html#initialize-instance_method" title="Puppeteer::NetworkManager#initialize (method)">new</a></span></span><span class='lparen'>(</span><span class='id identifier rubyid_client'>client</span><span class='comma'>,</span> <span class='id identifier rubyid_ignore_https_errors'>ignore_https_errors</span><span class='comma'>,</span> <span class='kw'>self</span><span class='rparen'>)</span>
827
+ <span class='ivar'>@timeout_settings</span> <span class='op'>=</span> <span class='id identifier rubyid_timeout_settings'>timeout_settings</span>
828
+
829
+ <span class='comment'># @type {!Map&lt;string, !Frame&gt;}
830
+ </span> <span class='ivar'>@frames</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span>
831
+
832
+ <span class='comment'># @type {!Map&lt;number, !ExecutionContext&gt;}
833
+ </span> <span class='ivar'>@context_id_to_context</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span>
834
+ <span class='ivar'>@context_id_created</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span>
835
+
836
+ <span class='comment'># @type {!Set&lt;string&gt;}
837
+ </span> <span class='ivar'>@isolated_worlds</span> <span class='op'>=</span> <span class='const'>Set</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span>
838
+
839
+ <span class='ivar'>@client</span><span class='period'>.</span><span class='id identifier rubyid_on_event'>on_event</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Page.frameAttached</span><span class='tstring_end'>&#39;</span></span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_event'>event</span><span class='op'>|</span>
840
+ <span class='id identifier rubyid_handle_frame_attached'>handle_frame_attached</span><span class='lparen'>(</span><span class='id identifier rubyid_event'>event</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>frameId</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id identifier rubyid_event'>event</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>parentFrameId</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rparen'>)</span>
841
+ <span class='kw'>end</span>
842
+ <span class='ivar'>@client</span><span class='period'>.</span><span class='id identifier rubyid_on_event'>on_event</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Page.frameNavigated</span><span class='tstring_end'>&#39;</span></span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_event'>event</span><span class='op'>|</span>
843
+ <span class='id identifier rubyid_handle_frame_navigated'>handle_frame_navigated</span><span class='lparen'>(</span><span class='id identifier rubyid_event'>event</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>frame</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rparen'>)</span>
844
+ <span class='kw'>end</span>
845
+ <span class='ivar'>@client</span><span class='period'>.</span><span class='id identifier rubyid_on_event'>on_event</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Page.navigatedWithinDocument</span><span class='tstring_end'>&#39;</span></span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_event'>event</span><span class='op'>|</span>
846
+ <span class='id identifier rubyid_handle_frame_navigated_within_document'>handle_frame_navigated_within_document</span><span class='lparen'>(</span><span class='id identifier rubyid_event'>event</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>frameId</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id identifier rubyid_event'>event</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>url</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rparen'>)</span>
847
+ <span class='kw'>end</span>
848
+ <span class='ivar'>@client</span><span class='period'>.</span><span class='id identifier rubyid_on_event'>on_event</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Page.frameDetached</span><span class='tstring_end'>&#39;</span></span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_event'>event</span><span class='op'>|</span>
849
+ <span class='id identifier rubyid_handle_frame_detached'>handle_frame_detached</span><span class='lparen'>(</span><span class='id identifier rubyid_event'>event</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>frameId</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rparen'>)</span>
850
+ <span class='kw'>end</span>
851
+ <span class='ivar'>@client</span><span class='period'>.</span><span class='id identifier rubyid_on_event'>on_event</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Page.frameStoppedLoading</span><span class='tstring_end'>&#39;</span></span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_event'>event</span><span class='op'>|</span>
852
+ <span class='id identifier rubyid_handle_frame_stopped_loading'>handle_frame_stopped_loading</span><span class='lparen'>(</span><span class='id identifier rubyid_event'>event</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>frameId</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rparen'>)</span>
853
+ <span class='kw'>end</span>
854
+ <span class='ivar'>@client</span><span class='period'>.</span><span class='id identifier rubyid_on_event'>on_event</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Runtime.executionContextCreated</span><span class='tstring_end'>&#39;</span></span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_event'>event</span><span class='op'>|</span>
855
+ <span class='id identifier rubyid_handle_execution_context_created'>handle_execution_context_created</span><span class='lparen'>(</span><span class='id identifier rubyid_event'>event</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>context</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rparen'>)</span>
856
+ <span class='kw'>end</span>
857
+ <span class='ivar'>@client</span><span class='period'>.</span><span class='id identifier rubyid_on_event'>on_event</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Runtime.executionContextDestroyed</span><span class='tstring_end'>&#39;</span></span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_event'>event</span><span class='op'>|</span>
858
+ <span class='id identifier rubyid_handle_execution_context_destroyed'>handle_execution_context_destroyed</span><span class='lparen'>(</span><span class='id identifier rubyid_event'>event</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>executionContextId</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rparen'>)</span>
859
+ <span class='kw'>end</span>
860
+ <span class='ivar'>@client</span><span class='period'>.</span><span class='id identifier rubyid_on_event'>on_event</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Runtime.executionContextsCleared</span><span class='tstring_end'>&#39;</span></span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_event'>event</span><span class='op'>|</span>
861
+ <span class='id identifier rubyid_handle_execution_contexts_cleared'>handle_execution_contexts_cleared</span>
862
+ <span class='kw'>end</span>
863
+ <span class='ivar'>@client</span><span class='period'>.</span><span class='id identifier rubyid_on_event'>on_event</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Page.lifecycleEvent</span><span class='tstring_end'>&#39;</span></span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_event'>event</span><span class='op'>|</span>
864
+ <span class='id identifier rubyid_handle_lifecycle_event'>handle_lifecycle_event</span><span class='lparen'>(</span><span class='id identifier rubyid_event'>event</span><span class='rparen'>)</span>
865
+ <span class='kw'>end</span>
866
+ <span class='kw'>end</span></pre>
867
+ </td>
868
+ </tr>
869
+ </table>
870
+ </div>
871
+
872
+ </div>
873
+
874
+ <div id="instance_attr_details" class="attr_details">
875
+ <h2>Instance Attribute Details</h2>
876
+
877
+
878
+ <span id=""></span>
879
+ <div class="method_details first">
880
+ <h3 class="signature first" id="client-instance_method">
881
+
882
+ #<strong>client</strong> &#x21d2; <tt>Object</tt> <span class="extras">(readonly)</span>
883
+
884
+
885
+
886
+
887
+
888
+ </h3><div class="docstring">
889
+ <div class="discussion">
890
+
891
+ <p>Returns the value of attribute client.</p>
892
+
893
+
894
+ </div>
895
+ </div>
896
+ <div class="tags">
897
+
898
+
899
+ </div><table class="source_code">
900
+ <tr>
901
+ <td>
902
+ <pre class="lines">
903
+
904
+
905
+ 60
906
+ 61
907
+ 62</pre>
908
+ </td>
909
+ <td>
910
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 60</span>
911
+
912
+ <span class='kw'>def</span> <span class='id identifier rubyid_client'>client</span>
913
+ <span class='ivar'>@client</span>
914
+ <span class='kw'>end</span></pre>
915
+ </td>
916
+ </tr>
917
+ </table>
918
+ </div>
919
+
920
+
921
+ <span id=""></span>
922
+ <div class="method_details ">
923
+ <h3 class="signature " id="network_manager-instance_method">
924
+
925
+ #<strong>network_manager</strong> &#x21d2; <tt>Object</tt> <span class="extras">(readonly)</span>
926
+
927
+
928
+
929
+
930
+
931
+ </h3><div class="docstring">
932
+ <div class="discussion">
933
+
934
+ <p>Returns the value of attribute network_manager.</p>
935
+
936
+
937
+ </div>
938
+ </div>
939
+ <div class="tags">
940
+
941
+
942
+ </div><table class="source_code">
943
+ <tr>
944
+ <td>
945
+ <pre class="lines">
946
+
947
+
948
+ 81
949
+ 82
950
+ 83</pre>
951
+ </td>
952
+ <td>
953
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 81</span>
954
+
955
+ <span class='kw'>def</span> <span class='id identifier rubyid_network_manager'>network_manager</span>
956
+ <span class='ivar'>@network_manager</span>
957
+ <span class='kw'>end</span></pre>
958
+ </td>
959
+ </tr>
960
+ </table>
961
+ </div>
962
+
963
+
964
+ <span id=""></span>
965
+ <div class="method_details ">
966
+ <h3 class="signature " id="timeout_settings-instance_method">
967
+
968
+ #<strong>timeout_settings</strong> &#x21d2; <tt>Object</tt> <span class="extras">(readonly)</span>
969
+
970
+
971
+
972
+
973
+
974
+ </h3><div class="docstring">
975
+ <div class="discussion">
976
+
977
+ <p>Returns the value of attribute timeout_settings.</p>
978
+
979
+
980
+ </div>
981
+ </div>
982
+ <div class="tags">
983
+
984
+
985
+ </div><table class="source_code">
986
+ <tr>
987
+ <td>
988
+ <pre class="lines">
989
+
990
+
991
+ 60
992
+ 61
993
+ 62</pre>
994
+ </td>
995
+ <td>
996
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 60</span>
997
+
998
+ <span class='kw'>def</span> <span class='id identifier rubyid_timeout_settings'>timeout_settings</span>
999
+ <span class='ivar'>@timeout_settings</span>
1000
+ <span class='kw'>end</span></pre>
1001
+ </td>
1002
+ </tr>
1003
+ </table>
1004
+ </div>
1005
+
1006
+ </div>
1007
+
1008
+
1009
+ <div id="instance_method_details" class="method_details_list">
1010
+ <h2>Instance Method Details</h2>
1011
+
1012
+
1013
+ <div class="method_details first">
1014
+ <h3 class="signature first" id="ensure_isolated_world-instance_method">
1015
+
1016
+ #<strong>ensure_isolated_world</strong>(name) &#x21d2; <tt>Object</tt>
1017
+
1018
+
1019
+
1020
+
1021
+
1022
+ </h3><div class="docstring">
1023
+ <div class="discussion">
1024
+
1025
+
1026
+ </div>
1027
+ </div>
1028
+ <div class="tags">
1029
+ <p class="tag_title">Parameters:</p>
1030
+ <ul class="param">
1031
+
1032
+ <li>
1033
+
1034
+ <span class='name'>name</span>
1035
+
1036
+
1037
+ <span class='type'>(<tt>String</tt>)</span>
1038
+
1039
+
1040
+
1041
+ </li>
1042
+
1043
+ </ul>
1044
+
1045
+
1046
+ </div><table class="source_code">
1047
+ <tr>
1048
+ <td>
1049
+ <pre class="lines">
1050
+
1051
+
1052
+ 262
1053
+ 263
1054
+ 264
1055
+ 265
1056
+ 266
1057
+ 267
1058
+ 268
1059
+ 269
1060
+ 270
1061
+ 271
1062
+ 272
1063
+ 273
1064
+ 274
1065
+ 275
1066
+ 276
1067
+ 277
1068
+ 278</pre>
1069
+ </td>
1070
+ <td>
1071
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 262</span>
1072
+
1073
+ <span class='kw'>def</span> <span class='id identifier rubyid_ensure_isolated_world'>ensure_isolated_world</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='rparen'>)</span>
1074
+ <span class='kw'>return</span> <span class='kw'>if</span> <span class='ivar'>@isolated_worlds</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>
1075
+ <span class='ivar'>@isolated_worlds</span> <span class='op'>&lt;&lt;</span> <span class='id identifier rubyid_name'>name</span>
1076
+
1077
+ <span class='ivar'>@client</span><span class='period'>.</span><span class='id identifier rubyid_send_message'>send_message</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Page.addScriptToEvaluateOnNewDocument</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span>
1078
+ <span class='label'>source:</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>//# sourceURL=</span><span class='embexpr_beg'>#{</span><span class='const'><span class='object_link'><a href="../Puppeteer.html" title="Puppeteer (class)">Puppeteer</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="ExecutionContext.html" title="Puppeteer::ExecutionContext (class)">ExecutionContext</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="ExecutionContext.html#EVALUATION_SCRIPT_URL-constant" title="Puppeteer::ExecutionContext::EVALUATION_SCRIPT_URL (constant)">EVALUATION_SCRIPT_URL</a></span></span><span class='embexpr_end'>}</span><span class='tstring_end'>&quot;</span></span><span class='comma'>,</span>
1079
+ <span class='label'>worldName:</span> <span class='id identifier rubyid_name'>name</span><span class='comma'>,</span>
1080
+ <span class='rparen'>)</span>
1081
+ <span class='id identifier rubyid_create_isolated_worlds_promises'>create_isolated_worlds_promises</span> <span class='op'>=</span> <span class='id identifier rubyid_frames'>frames</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_frame'>frame</span><span class='op'>|</span>
1082
+ <span class='ivar'>@client</span><span class='period'>.</span><span class='id identifier rubyid_async_send_message'>async_send_message</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Page.createIsolatedWorld</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span>
1083
+ <span class='label'>frameId:</span> <span class='id identifier rubyid_frame'>frame</span><span class='period'>.</span><span class='id identifier rubyid_id'>id</span><span class='comma'>,</span>
1084
+ <span class='label'>grantUniveralAccess:</span> <span class='kw'>true</span><span class='comma'>,</span>
1085
+ <span class='label'>worldName:</span> <span class='id identifier rubyid_name'>name</span><span class='comma'>,</span>
1086
+ <span class='rparen'>)</span>
1087
+ <span class='kw'>end</span>
1088
+ <span class='id identifier rubyid_await_all'><span class='object_link'><a href="ConcurrentRubyUtils.html#await_all-instance_method" title="Puppeteer::ConcurrentRubyUtils#await_all (method)">await_all</a></span></span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_create_isolated_worlds_promises'>create_isolated_worlds_promises</span><span class='rparen'>)</span>
1089
+ <span class='kw'>end</span></pre>
1090
+ </td>
1091
+ </tr>
1092
+ </table>
1093
+ </div>
1094
+
1095
+ <div class="method_details ">
1096
+ <h3 class="signature " id="execution_context_by_id-instance_method">
1097
+
1098
+ #<strong>execution_context_by_id</strong>(context_id) &#x21d2; <tt>Object</tt>
1099
+
1100
+
1101
+
1102
+
1103
+
1104
+ </h3><table class="source_code">
1105
+ <tr>
1106
+ <td>
1107
+ <pre class="lines">
1108
+
1109
+
1110
+ 357
1111
+ 358
1112
+ 359
1113
+ 360
1114
+ 361
1115
+ 362
1116
+ 363</pre>
1117
+ </td>
1118
+ <td>
1119
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 357</span>
1120
+
1121
+ <span class='kw'>def</span> <span class='id identifier rubyid_execution_context_by_id'>execution_context_by_id</span><span class='lparen'>(</span><span class='id identifier rubyid_context_id'>context_id</span><span class='rparen'>)</span>
1122
+ <span class='id identifier rubyid_context'>context</span> <span class='op'>=</span> <span class='ivar'>@context_id_to_context</span><span class='lbracket'>[</span><span class='id identifier rubyid_context_id'>context_id</span><span class='rbracket'>]</span>
1123
+ <span class='kw'>if</span> <span class='op'>!</span><span class='id identifier rubyid_context'>context</span>
1124
+ <span class='id identifier rubyid_raise'>raise</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>INTERNAL ERROR: missing context with id = </span><span class='embexpr_beg'>#{</span><span class='id identifier rubyid_context_id'>context_id</span><span class='embexpr_end'>}</span><span class='tstring_end'>&quot;</span></span>
1125
+ <span class='kw'>end</span>
1126
+ <span class='id identifier rubyid_context'>context</span>
1127
+ <span class='kw'>end</span></pre>
1128
+ </td>
1129
+ </tr>
1130
+ </table>
1131
+ </div>
1132
+
1133
+ <div class="method_details ">
1134
+ <h3 class="signature " id="frame-instance_method">
1135
+
1136
+ #<strong>frame</strong>(frame_id) &#x21d2; <tt>?<span class='object_link'><a href="Frame.html" title="Puppeteer::Frame (class)">Frame</a></span></tt>
1137
+
1138
+
1139
+
1140
+
1141
+
1142
+ </h3><div class="docstring">
1143
+ <div class="discussion">
1144
+
1145
+
1146
+ </div>
1147
+ </div>
1148
+ <div class="tags">
1149
+ <p class="tag_title">Parameters:</p>
1150
+ <ul class="param">
1151
+
1152
+ <li>
1153
+
1154
+ <span class='name'>frameId</span>
1155
+
1156
+
1157
+ <span class='type'>(<tt>!string</tt>)</span>
1158
+
1159
+
1160
+
1161
+ </li>
1162
+
1163
+ </ul>
1164
+
1165
+ <p class="tag_title">Returns:</p>
1166
+ <ul class="return">
1167
+
1168
+ <li>
1169
+
1170
+
1171
+ <span class='type'>(<tt>?<span class='object_link'><a href="Frame.html" title="Puppeteer::Frame (class)">Frame</a></span></tt>)</span>
1172
+
1173
+
1174
+
1175
+ </li>
1176
+
1177
+ </ul>
1178
+
1179
+ </div><table class="source_code">
1180
+ <tr>
1181
+ <td>
1182
+ <pre class="lines">
1183
+
1184
+
1185
+ 202
1186
+ 203
1187
+ 204</pre>
1188
+ </td>
1189
+ <td>
1190
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 202</span>
1191
+
1192
+ <span class='kw'>def</span> <span class='id identifier rubyid_frame'>frame</span><span class='lparen'>(</span><span class='id identifier rubyid_frame_id'>frame_id</span><span class='rparen'>)</span>
1193
+ <span class='ivar'>@frames</span><span class='lbracket'>[</span><span class='id identifier rubyid_frame_id'>frame_id</span><span class='rbracket'>]</span>
1194
+ <span class='kw'>end</span></pre>
1195
+ </td>
1196
+ </tr>
1197
+ </table>
1198
+ </div>
1199
+
1200
+ <div class="method_details ">
1201
+ <h3 class="signature " id="frames-instance_method">
1202
+
1203
+ #<strong>frames</strong> &#x21d2; <tt>!Array&lt;!<span class='object_link'><a href="Frame.html" title="Puppeteer::Frame (class)">Frame</a></span>&gt;</tt>
1204
+
1205
+
1206
+
1207
+
1208
+
1209
+ </h3><div class="docstring">
1210
+ <div class="discussion">
1211
+
1212
+
1213
+ </div>
1214
+ </div>
1215
+ <div class="tags">
1216
+
1217
+ <p class="tag_title">Returns:</p>
1218
+ <ul class="return">
1219
+
1220
+ <li>
1221
+
1222
+
1223
+ <span class='type'>(<tt>!Array&lt;!<span class='object_link'><a href="Frame.html" title="Puppeteer::Frame (class)">Frame</a></span>&gt;</tt>)</span>
1224
+
1225
+
1226
+
1227
+ </li>
1228
+
1229
+ </ul>
1230
+
1231
+ </div><table class="source_code">
1232
+ <tr>
1233
+ <td>
1234
+ <pre class="lines">
1235
+
1236
+
1237
+ 196
1238
+ 197
1239
+ 198</pre>
1240
+ </td>
1241
+ <td>
1242
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 196</span>
1243
+
1244
+ <span class='kw'>def</span> <span class='id identifier rubyid_frames'>frames</span>
1245
+ <span class='ivar'>@frames</span><span class='period'>.</span><span class='id identifier rubyid_values'>values</span>
1246
+ <span class='kw'>end</span></pre>
1247
+ </td>
1248
+ </tr>
1249
+ </table>
1250
+ </div>
1251
+
1252
+ <div class="method_details ">
1253
+ <h3 class="signature " id="handle_execution_context_created-instance_method">
1254
+
1255
+ #<strong>handle_execution_context_created</strong>(context_payload) &#x21d2; <tt>Object</tt>
1256
+
1257
+
1258
+
1259
+
1260
+
1261
+ </h3><div class="docstring">
1262
+ <div class="discussion">
1263
+
1264
+
1265
+ </div>
1266
+ </div>
1267
+ <div class="tags">
1268
+ <p class="tag_title">Parameters:</p>
1269
+ <ul class="param">
1270
+
1271
+ <li>
1272
+
1273
+ <span class='name'>context_payload</span>
1274
+
1275
+
1276
+ <span class='type'>(<tt>Hash</tt>)</span>
1277
+
1278
+
1279
+
1280
+ </li>
1281
+
1282
+ </ul>
1283
+
1284
+
1285
+ </div><table class="source_code">
1286
+ <tr>
1287
+ <td>
1288
+ <pre class="lines">
1289
+
1290
+
1291
+ 301
1292
+ 302
1293
+ 303
1294
+ 304
1295
+ 305
1296
+ 306
1297
+ 307
1298
+ 308
1299
+ 309
1300
+ 310
1301
+ 311
1302
+ 312
1303
+ 313
1304
+ 314
1305
+ 315
1306
+ 316
1307
+ 317
1308
+ 318
1309
+ 319
1310
+ 320
1311
+ 321
1312
+ 322
1313
+ 323
1314
+ 324
1315
+ 325
1316
+ 326</pre>
1317
+ </td>
1318
+ <td>
1319
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 301</span>
1320
+
1321
+ <span class='kw'>def</span> <span class='id identifier rubyid_handle_execution_context_created'>handle_execution_context_created</span><span class='lparen'>(</span><span class='id identifier rubyid_context_payload'>context_payload</span><span class='rparen'>)</span>
1322
+ <span class='id identifier rubyid_frame'>frame</span> <span class='op'>=</span> <span class='id identifier rubyid_if_present'>if_present</span><span class='lparen'>(</span><span class='id identifier rubyid_context_payload'>context_payload</span><span class='period'>.</span><span class='id identifier rubyid_dig'>dig</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>auxData</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>frameId</span><span class='tstring_end'>&#39;</span></span><span class='rparen'>)</span><span class='rparen'>)</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id identifier rubyid_frame_id'>frame_id</span><span class='op'>|</span> <span class='ivar'>@frames</span><span class='lbracket'>[</span><span class='id identifier rubyid_frame_id'>frame_id</span><span class='rbracket'>]</span> <span class='rbrace'>}</span>
1323
+
1324
+ <span class='id identifier rubyid_world'>world</span> <span class='op'>=</span> <span class='kw'>nil</span>
1325
+ <span class='kw'>if</span> <span class='id identifier rubyid_frame'>frame</span>
1326
+ <span class='kw'>if</span> <span class='id identifier rubyid_context_payload'>context_payload</span><span class='period'>.</span><span class='id identifier rubyid_dig'>dig</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>auxData</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>isDefault</span><span class='tstring_end'>&#39;</span></span><span class='rparen'>)</span>
1327
+ <span class='id identifier rubyid_world'>world</span> <span class='op'>=</span> <span class='id identifier rubyid_frame'>frame</span><span class='period'>.</span><span class='id identifier rubyid_main_world'>main_world</span>
1328
+ <span class='kw'>elsif</span> <span class='id identifier rubyid_context_payload'>context_payload</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>name</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span> <span class='op'>==</span> <span class='const'><span class='object_link'><a href="#UTILITY_WORLD_NAME-constant" title="Puppeteer::FrameManager::UTILITY_WORLD_NAME (constant)">UTILITY_WORLD_NAME</a></span></span> <span class='op'>&amp;&amp;</span> <span class='op'>!</span><span class='id identifier rubyid_frame'>frame</span><span class='period'>.</span><span class='id identifier rubyid_secondary_world'>secondary_world</span><span class='period'>.</span><span class='id identifier rubyid_has_context?'>has_context?</span>
1329
+ <span class='comment'># In case of multiple sessions to the same target, there&#39;s a race between
1330
+ </span> <span class='comment'># connections so we might end up creating multiple isolated worlds.
1331
+ </span> <span class='comment'># We can use either.
1332
+ </span> <span class='id identifier rubyid_world'>world</span> <span class='op'>=</span> <span class='id identifier rubyid_frame'>frame</span><span class='period'>.</span><span class='id identifier rubyid_secondary_world'>secondary_world</span>
1333
+ <span class='kw'>end</span>
1334
+ <span class='kw'>end</span>
1335
+
1336
+ <span class='kw'>if</span> <span class='id identifier rubyid_context_payload'>context_payload</span><span class='period'>.</span><span class='id identifier rubyid_dig'>dig</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>auxData</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>type</span><span class='tstring_end'>&#39;</span></span><span class='rparen'>)</span> <span class='op'>==</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>isolated</span><span class='tstring_end'>&#39;</span></span>
1337
+ <span class='ivar'>@isolated_worlds</span> <span class='op'>&lt;&lt;</span> <span class='id identifier rubyid_context_payload'>context_payload</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>name</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span>
1338
+ <span class='kw'>end</span>
1339
+
1340
+ <span class='id identifier rubyid_context'>context</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="../Puppeteer.html" title="Puppeteer (class)">Puppeteer</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="ExecutionContext.html" title="Puppeteer::ExecutionContext (class)">ExecutionContext</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="ExecutionContext.html#initialize-instance_method" title="Puppeteer::ExecutionContext#initialize (method)">new</a></span></span><span class='lparen'>(</span><span class='ivar'>@client</span><span class='comma'>,</span> <span class='id identifier rubyid_context_payload'>context_payload</span><span class='comma'>,</span> <span class='id identifier rubyid_world'>world</span><span class='rparen'>)</span>
1341
+ <span class='kw'>if</span> <span class='id identifier rubyid_world'>world</span>
1342
+ <span class='id identifier rubyid_world'>world</span><span class='period'>.</span><span class='id identifier rubyid_context'>context</span> <span class='op'>=</span> <span class='id identifier rubyid_context'>context</span>
1343
+ <span class='kw'>end</span>
1344
+ <span class='ivar'>@context_id_to_context</span><span class='lbracket'>[</span><span class='id identifier rubyid_context_payload'>context_payload</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>id</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_context'>context</span>
1345
+ <span class='ivar'>@context_id_created</span><span class='lbracket'>[</span><span class='id identifier rubyid_context_payload'>context_payload</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>id</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='const'>Time</span><span class='period'>.</span><span class='id identifier rubyid_now'>now</span>
1346
+ <span class='kw'>end</span></pre>
1347
+ </td>
1348
+ </tr>
1349
+ </table>
1350
+ </div>
1351
+
1352
+ <div class="method_details ">
1353
+ <h3 class="signature " id="handle_execution_context_destroyed-instance_method">
1354
+
1355
+ #<strong>handle_execution_context_destroyed</strong>(execution_context_id) &#x21d2; <tt>Object</tt>
1356
+
1357
+
1358
+
1359
+
1360
+
1361
+ </h3><div class="docstring">
1362
+ <div class="discussion">
1363
+
1364
+
1365
+ </div>
1366
+ </div>
1367
+ <div class="tags">
1368
+ <p class="tag_title">Parameters:</p>
1369
+ <ul class="param">
1370
+
1371
+ <li>
1372
+
1373
+ <span class='name'>executionContextId</span>
1374
+
1375
+
1376
+ <span class='type'>(<tt>number</tt>)</span>
1377
+
1378
+
1379
+
1380
+ </li>
1381
+
1382
+ </ul>
1383
+
1384
+
1385
+ </div><table class="source_code">
1386
+ <tr>
1387
+ <td>
1388
+ <pre class="lines">
1389
+
1390
+
1391
+ 329
1392
+ 330
1393
+ 331
1394
+ 332
1395
+ 333
1396
+ 334
1397
+ 335
1398
+ 336
1399
+ 337</pre>
1400
+ </td>
1401
+ <td>
1402
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 329</span>
1403
+
1404
+ <span class='kw'>def</span> <span class='id identifier rubyid_handle_execution_context_destroyed'>handle_execution_context_destroyed</span><span class='lparen'>(</span><span class='id identifier rubyid_execution_context_id'>execution_context_id</span><span class='rparen'>)</span>
1405
+ <span class='id identifier rubyid_context'>context</span> <span class='op'>=</span> <span class='ivar'>@context_id_to_context</span><span class='lbracket'>[</span><span class='id identifier rubyid_execution_context_id'>execution_context_id</span><span class='rbracket'>]</span>
1406
+ <span class='kw'>return</span> <span class='kw'>if</span> <span class='op'>!</span><span class='id identifier rubyid_context'>context</span>
1407
+ <span class='ivar'>@context_id_to_context</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='id identifier rubyid_execution_context_id'>execution_context_id</span><span class='rparen'>)</span>
1408
+ <span class='ivar'>@context_id_created</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='id identifier rubyid_execution_context_id'>execution_context_id</span><span class='rparen'>)</span>
1409
+ <span class='kw'>if</span> <span class='id identifier rubyid_context'>context</span><span class='period'>.</span><span class='id identifier rubyid_world'>world</span>
1410
+ <span class='id identifier rubyid_context'>context</span><span class='period'>.</span><span class='id identifier rubyid_world'>world</span><span class='period'>.</span><span class='id identifier rubyid_delete_context'>delete_context</span><span class='lparen'>(</span><span class='id identifier rubyid_execution_context_id'>execution_context_id</span><span class='rparen'>)</span>
1411
+ <span class='kw'>end</span>
1412
+ <span class='kw'>end</span></pre>
1413
+ </td>
1414
+ </tr>
1415
+ </table>
1416
+ </div>
1417
+
1418
+ <div class="method_details ">
1419
+ <h3 class="signature " id="handle_execution_contexts_cleared-instance_method">
1420
+
1421
+ #<strong>handle_execution_contexts_cleared</strong> &#x21d2; <tt>Object</tt>
1422
+
1423
+
1424
+
1425
+
1426
+
1427
+ </h3><table class="source_code">
1428
+ <tr>
1429
+ <td>
1430
+ <pre class="lines">
1431
+
1432
+
1433
+ 339
1434
+ 340
1435
+ 341
1436
+ 342
1437
+ 343
1438
+ 344
1439
+ 345
1440
+ 346
1441
+ 347
1442
+ 348
1443
+ 349
1444
+ 350
1445
+ 351
1446
+ 352
1447
+ 353
1448
+ 354
1449
+ 355</pre>
1450
+ </td>
1451
+ <td>
1452
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 339</span>
1453
+
1454
+ <span class='kw'>def</span> <span class='id identifier rubyid_handle_execution_contexts_cleared'>handle_execution_contexts_cleared</span>
1455
+ <span class='comment'># executionContextsCleared is often notified after executionContextCreated.
1456
+ </span> <span class='comment'># D, [2020-04-06T01:47:03.101227 #13823] DEBUG -- : RECV &lt;&lt; {&quot;method&quot;=&gt;&quot;Runtime.executionContextCreated&quot;, &quot;params&quot;=&gt;{&quot;context&quot;=&gt;{&quot;id&quot;=&gt;5, &quot;origin&quot;=&gt;&quot;https://github.com&quot;, &quot;name&quot;=&gt;&quot;&quot;, &quot;auxData&quot;=&gt;{&quot;isDefault&quot;=&gt;true, &quot;type&quot;=&gt;&quot;default&quot;, &quot;frameId&quot;=&gt;&quot;71C347B70848B89DDDEFAA8AB5B0BC92&quot;}}}, &quot;sessionId&quot;=&gt;&quot;53F088EED260C28001D26A019F95D9E3&quot;}
1457
+ </span> <span class='comment'># D, [2020-04-06T01:47:03.101439 #13823] DEBUG -- : RECV &lt;&lt; {&quot;method&quot;=&gt;&quot;Page.frameNavigated&quot;, &quot;params&quot;=&gt;{&quot;frame&quot;=&gt;{&quot;id&quot;=&gt;&quot;71C347B70848B89DDDEFAA8AB5B0BC92&quot;, &quot;loaderId&quot;=&gt;&quot;80338225D035AC96BAE8F6D4E81C7D51&quot;, &quot;url&quot;=&gt;&quot;https://github.com/search?q=puppeteer&quot;, &quot;securityOrigin&quot;=&gt;&quot;https://github.com&quot;, &quot;mimeType&quot;=&gt;&quot;text/html&quot;}}, &quot;sessionId&quot;=&gt;&quot;53F088EED260C28001D26A019F95D9E3&quot;}
1458
+ </span> <span class='comment'># D, [2020-04-06T01:47:03.101325 #13823] DEBUG -- : RECV &lt;&lt; {&quot;method&quot;=&gt;&quot;Target.targetInfoChanged&quot;, &quot;params&quot;=&gt;{&quot;targetInfo&quot;=&gt;{&quot;targetId&quot;=&gt;&quot;71C347B70848B89DDDEFAA8AB5B0BC92&quot;, &quot;type&quot;=&gt;&quot;page&quot;, &quot;title&quot;=&gt;&quot;https://github.com/search?q=puppeteer&quot;, &quot;url&quot;=&gt;&quot;https://github.com/search?q=puppeteer&quot;, &quot;attached&quot;=&gt;true, &quot;browserContextId&quot;=&gt;&quot;AF37BC660284CE1552B4ECB147BE9305&quot;}}}
1459
+ </span> <span class='comment'># D, [2020-04-06T01:47:03.101269 #13823] DEBUG -- : RECV &lt;&lt; {&quot;method&quot;=&gt;&quot;Runtime.executionContextsCleared&quot;, &quot;params&quot;=&gt;{}, &quot;sessionId&quot;=&gt;&quot;53F088EED260C28001D26A019F95D9E3&quot;}
1460
+ </span> <span class='comment'># it unexpectedly clears the created execution context.
1461
+ </span> <span class='comment'># To avoid the problem, just skip recent created ids.
1462
+ </span> <span class='id identifier rubyid_now'>now</span> <span class='op'>=</span> <span class='const'>Time</span><span class='period'>.</span><span class='id identifier rubyid_now'>now</span>
1463
+ <span class='id identifier rubyid_context_ids_to_skip'>context_ids_to_skip</span> <span class='op'>=</span> <span class='ivar'>@context_id_created</span><span class='period'>.</span><span class='id identifier rubyid_select'>select</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_now'>now</span> <span class='op'>-</span> <span class='id identifier rubyid_v'>v</span> <span class='op'>&lt;</span> <span class='int'>1</span> <span class='rbrace'>}</span><span class='period'>.</span><span class='id identifier rubyid_keys'>keys</span>
1464
+ <span class='ivar'>@context_id_to_context</span><span class='period'>.</span><span class='id identifier rubyid_reject'>reject</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_context_ids_to_skip'>context_ids_to_skip</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='rparen'>)</span> <span class='rbrace'>}</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_execution_context_id'>execution_context_id</span><span class='comma'>,</span> <span class='id identifier rubyid_context'>context</span><span class='op'>|</span>
1465
+ <span class='kw'>if</span> <span class='id identifier rubyid_context'>context</span><span class='period'>.</span><span class='id identifier rubyid_world'>world</span>
1466
+ <span class='id identifier rubyid_context'>context</span><span class='period'>.</span><span class='id identifier rubyid_world'>world</span><span class='period'>.</span><span class='id identifier rubyid_delete_context'>delete_context</span><span class='lparen'>(</span><span class='id identifier rubyid_execution_context_id'>execution_context_id</span><span class='rparen'>)</span>
1467
+ <span class='kw'>end</span>
1468
+ <span class='kw'>end</span>
1469
+ <span class='ivar'>@context_id_to_context</span><span class='period'>.</span><span class='id identifier rubyid_select!'>select!</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_context_ids_to_skip'>context_ids_to_skip</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='rparen'>)</span> <span class='rbrace'>}</span>
1470
+ <span class='kw'>end</span></pre>
1471
+ </td>
1472
+ </tr>
1473
+ </table>
1474
+ </div>
1475
+
1476
+ <div class="method_details ">
1477
+ <h3 class="signature " id="handle_frame_attached-instance_method">
1478
+
1479
+ #<strong>handle_frame_attached</strong>(frame_id, parent_frame_id) &#x21d2; <tt>Object</tt>
1480
+
1481
+
1482
+
1483
+
1484
+
1485
+ </h3><div class="docstring">
1486
+ <div class="discussion">
1487
+
1488
+
1489
+ </div>
1490
+ </div>
1491
+ <div class="tags">
1492
+ <p class="tag_title">Parameters:</p>
1493
+ <ul class="param">
1494
+
1495
+ <li>
1496
+
1497
+ <span class='name'>frameId</span>
1498
+
1499
+
1500
+ <span class='type'>(<tt>string</tt>)</span>
1501
+
1502
+
1503
+
1504
+ </li>
1505
+
1506
+ <li>
1507
+
1508
+ <span class='name'>parentFrameId</span>
1509
+
1510
+
1511
+ <span class='type'>(<tt>?string</tt>)</span>
1512
+
1513
+
1514
+
1515
+ </li>
1516
+
1517
+ </ul>
1518
+
1519
+
1520
+ </div><table class="source_code">
1521
+ <tr>
1522
+ <td>
1523
+ <pre class="lines">
1524
+
1525
+
1526
+ 208
1527
+ 209
1528
+ 210
1529
+ 211
1530
+ 212
1531
+ 213
1532
+ 214
1533
+ 215
1534
+ 216
1535
+ 217
1536
+ 218</pre>
1537
+ </td>
1538
+ <td>
1539
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 208</span>
1540
+
1541
+ <span class='kw'>def</span> <span class='id identifier rubyid_handle_frame_attached'>handle_frame_attached</span><span class='lparen'>(</span><span class='id identifier rubyid_frame_id'>frame_id</span><span class='comma'>,</span> <span class='id identifier rubyid_parent_frame_id'>parent_frame_id</span><span class='rparen'>)</span>
1542
+ <span class='kw'>return</span> <span class='kw'>if</span> <span class='ivar'>@frames</span><span class='period'>.</span><span class='id identifier rubyid_has_key?'>has_key?</span><span class='lparen'>(</span><span class='id identifier rubyid_frame_id'>frame_id</span><span class='rparen'>)</span>
1543
+ <span class='kw'>if</span> <span class='op'>!</span><span class='id identifier rubyid_parent_frame_id'>parent_frame_id</span>
1544
+ <span class='id identifier rubyid_raise'>raise</span> <span class='const'>ArgymentError</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>parent_frame_id must not be nil</span><span class='tstring_end'>&#39;</span></span><span class='rparen'>)</span>
1545
+ <span class='kw'>end</span>
1546
+ <span class='id identifier rubyid_parent_frame'>parent_frame</span> <span class='op'>=</span> <span class='ivar'>@frames</span><span class='lbracket'>[</span><span class='id identifier rubyid_parent_frame_id'>parent_frame_id</span><span class='rbracket'>]</span>
1547
+ <span class='id identifier rubyid_frame'>frame</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="../Puppeteer.html" title="Puppeteer (class)">Puppeteer</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="Frame.html" title="Puppeteer::Frame (class)">Frame</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="Frame.html#initialize-instance_method" title="Puppeteer::Frame#initialize (method)">new</a></span></span><span class='lparen'>(</span><span class='kw'>self</span><span class='comma'>,</span> <span class='ivar'>@client</span><span class='comma'>,</span> <span class='id identifier rubyid_parent_frame'>parent_frame</span><span class='comma'>,</span> <span class='id identifier rubyid_frame_id'>frame_id</span><span class='rparen'>)</span>
1548
+ <span class='ivar'>@frames</span><span class='lbracket'>[</span><span class='id identifier rubyid_frame_id'>frame_id</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_frame'>frame</span>
1549
+
1550
+ <span class='id identifier rubyid_emit_event'>emit_event</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Events.FrameManager.FrameAttached</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='id identifier rubyid_frame'>frame</span>
1551
+ <span class='kw'>end</span></pre>
1552
+ </td>
1553
+ </tr>
1554
+ </table>
1555
+ </div>
1556
+
1557
+ <div class="method_details ">
1558
+ <h3 class="signature " id="handle_frame_detached-instance_method">
1559
+
1560
+ #<strong>handle_frame_detached</strong>(frame_id) &#x21d2; <tt>Object</tt>
1561
+
1562
+
1563
+
1564
+
1565
+
1566
+ </h3><div class="docstring">
1567
+ <div class="discussion">
1568
+
1569
+
1570
+ </div>
1571
+ </div>
1572
+ <div class="tags">
1573
+ <p class="tag_title">Parameters:</p>
1574
+ <ul class="param">
1575
+
1576
+ <li>
1577
+
1578
+ <span class='name'>frame_id</span>
1579
+
1580
+
1581
+ <span class='type'>(<tt>String</tt>)</span>
1582
+
1583
+
1584
+
1585
+ </li>
1586
+
1587
+ </ul>
1588
+
1589
+
1590
+ </div><table class="source_code">
1591
+ <tr>
1592
+ <td>
1593
+ <pre class="lines">
1594
+
1595
+
1596
+ 293
1597
+ 294
1598
+ 295
1599
+ 296
1600
+ 297
1601
+ 298</pre>
1602
+ </td>
1603
+ <td>
1604
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 293</span>
1605
+
1606
+ <span class='kw'>def</span> <span class='id identifier rubyid_handle_frame_detached'>handle_frame_detached</span><span class='lparen'>(</span><span class='id identifier rubyid_frame_id'>frame_id</span><span class='rparen'>)</span>
1607
+ <span class='id identifier rubyid_frame'>frame</span> <span class='op'>=</span> <span class='ivar'>@frames</span><span class='lbracket'>[</span><span class='id identifier rubyid_frame_id'>frame_id</span><span class='rbracket'>]</span>
1608
+ <span class='kw'>if</span> <span class='id identifier rubyid_frame'>frame</span>
1609
+ <span class='id identifier rubyid_remove_frame_recursively'>remove_frame_recursively</span><span class='lparen'>(</span><span class='id identifier rubyid_frame'>frame</span><span class='rparen'>)</span>
1610
+ <span class='kw'>end</span>
1611
+ <span class='kw'>end</span></pre>
1612
+ </td>
1613
+ </tr>
1614
+ </table>
1615
+ </div>
1616
+
1617
+ <div class="method_details ">
1618
+ <h3 class="signature " id="handle_frame_navigated-instance_method">
1619
+
1620
+ #<strong>handle_frame_navigated</strong>(frame_payload) &#x21d2; <tt>Object</tt>
1621
+
1622
+
1623
+
1624
+
1625
+
1626
+ </h3><div class="docstring">
1627
+ <div class="discussion">
1628
+
1629
+
1630
+ </div>
1631
+ </div>
1632
+ <div class="tags">
1633
+ <p class="tag_title">Parameters:</p>
1634
+ <ul class="param">
1635
+
1636
+ <li>
1637
+
1638
+ <span class='name'>frame_payload</span>
1639
+
1640
+
1641
+ <span class='type'>(<tt>Hash</tt>)</span>
1642
+
1643
+
1644
+
1645
+ </li>
1646
+
1647
+ </ul>
1648
+
1649
+
1650
+ </div><table class="source_code">
1651
+ <tr>
1652
+ <td>
1653
+ <pre class="lines">
1654
+
1655
+
1656
+ 221
1657
+ 222
1658
+ 223
1659
+ 224
1660
+ 225
1661
+ 226
1662
+ 227
1663
+ 228
1664
+ 229
1665
+ 230
1666
+ 231
1667
+ 232
1668
+ 233
1669
+ 234
1670
+ 235
1671
+ 236
1672
+ 237
1673
+ 238
1674
+ 239
1675
+ 240
1676
+ 241
1677
+ 242
1678
+ 243
1679
+ 244
1680
+ 245
1681
+ 246
1682
+ 247
1683
+ 248
1684
+ 249
1685
+ 250
1686
+ 251
1687
+ 252
1688
+ 253
1689
+ 254
1690
+ 255
1691
+ 256
1692
+ 257
1693
+ 258
1694
+ 259</pre>
1695
+ </td>
1696
+ <td>
1697
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 221</span>
1698
+
1699
+ <span class='kw'>def</span> <span class='id identifier rubyid_handle_frame_navigated'>handle_frame_navigated</span><span class='lparen'>(</span><span class='id identifier rubyid_frame_payload'>frame_payload</span><span class='rparen'>)</span>
1700
+ <span class='id identifier rubyid_is_main_frame'>is_main_frame</span> <span class='op'>=</span> <span class='op'>!</span><span class='id identifier rubyid_frame_payload'>frame_payload</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>parentId</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span>
1701
+ <span class='id identifier rubyid_frame'>frame</span> <span class='op'>=</span>
1702
+ <span class='kw'>if</span> <span class='id identifier rubyid_is_main_frame'>is_main_frame</span>
1703
+ <span class='ivar'>@main_frame</span>
1704
+ <span class='kw'>else</span>
1705
+ <span class='ivar'>@frames</span><span class='lbracket'>[</span><span class='id identifier rubyid_frame_payload'>frame_payload</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>id</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rbracket'>]</span>
1706
+ <span class='kw'>end</span>
1707
+
1708
+ <span class='kw'>if</span> <span class='op'>!</span><span class='id identifier rubyid_is_main_frame'>is_main_frame</span> <span class='op'>&amp;&amp;</span> <span class='op'>!</span><span class='id identifier rubyid_frame'>frame</span>
1709
+ <span class='id identifier rubyid_raise'>raise</span> <span class='const'>ArgumentError</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>We either navigate top level or have old version of the navigated frame</span><span class='tstring_end'>&#39;</span></span><span class='rparen'>)</span>
1710
+ <span class='kw'>end</span>
1711
+
1712
+ <span class='comment'># Detach all child frames first.
1713
+ </span> <span class='kw'>if</span> <span class='id identifier rubyid_frame'>frame</span>
1714
+ <span class='id identifier rubyid_frame'>frame</span><span class='period'>.</span><span class='id identifier rubyid_child_frames'>child_frames</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_child'>child</span><span class='op'>|</span>
1715
+ <span class='id identifier rubyid_remove_frame_recursively'>remove_frame_recursively</span><span class='lparen'>(</span><span class='id identifier rubyid_child'>child</span><span class='rparen'>)</span>
1716
+ <span class='kw'>end</span>
1717
+ <span class='kw'>end</span>
1718
+
1719
+ <span class='comment'># Update or create main frame.
1720
+ </span> <span class='kw'>if</span> <span class='id identifier rubyid_is_main_frame'>is_main_frame</span>
1721
+ <span class='kw'>if</span> <span class='id identifier rubyid_frame'>frame</span>
1722
+ <span class='comment'># Update frame id to retain frame identity on cross-process navigation.
1723
+ </span> <span class='ivar'>@frames</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='id identifier rubyid_frame'>frame</span><span class='period'>.</span><span class='id identifier rubyid_id'>id</span><span class='rparen'>)</span>
1724
+ <span class='id identifier rubyid_frame'>frame</span><span class='period'>.</span><span class='id identifier rubyid_id'>id</span> <span class='op'>=</span> <span class='id identifier rubyid_frame_payload'>frame_payload</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>id</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span>
1725
+ <span class='kw'>else</span>
1726
+ <span class='comment'># Initial main frame navigation.
1727
+ </span> <span class='id identifier rubyid_frame'>frame</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="../Puppeteer.html" title="Puppeteer (class)">Puppeteer</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="Frame.html" title="Puppeteer::Frame (class)">Frame</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="Frame.html#initialize-instance_method" title="Puppeteer::Frame#initialize (method)">new</a></span></span><span class='lparen'>(</span><span class='kw'>self</span><span class='comma'>,</span> <span class='ivar'>@client</span><span class='comma'>,</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='id identifier rubyid_frame_payload'>frame_payload</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>id</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rparen'>)</span>
1728
+ <span class='kw'>end</span>
1729
+ <span class='ivar'>@frames</span><span class='lbracket'>[</span><span class='id identifier rubyid_frame_payload'>frame_payload</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>id</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_frame'>frame</span>
1730
+ <span class='ivar'>@main_frame</span> <span class='op'>=</span> <span class='id identifier rubyid_frame'>frame</span>
1731
+ <span class='kw'>end</span>
1732
+
1733
+ <span class='comment'># Update frame payload.
1734
+ </span> <span class='id identifier rubyid_frame'>frame</span><span class='period'>.</span><span class='id identifier rubyid_navigated'>navigated</span><span class='lparen'>(</span><span class='id identifier rubyid_frame_payload'>frame_payload</span><span class='rparen'>)</span>
1735
+
1736
+ <span class='id identifier rubyid_emit_event'>emit_event</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Events.FrameManager.FrameNavigated</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='id identifier rubyid_frame'>frame</span>
1737
+ <span class='kw'>end</span></pre>
1738
+ </td>
1739
+ </tr>
1740
+ </table>
1741
+ </div>
1742
+
1743
+ <div class="method_details ">
1744
+ <h3 class="signature " id="handle_frame_navigated_within_document-instance_method">
1745
+
1746
+ #<strong>handle_frame_navigated_within_document</strong>(frame_id, url) &#x21d2; <tt>Object</tt>
1747
+
1748
+
1749
+
1750
+
1751
+
1752
+ </h3><div class="docstring">
1753
+ <div class="discussion">
1754
+
1755
+
1756
+ </div>
1757
+ </div>
1758
+ <div class="tags">
1759
+ <p class="tag_title">Parameters:</p>
1760
+ <ul class="param">
1761
+
1762
+ <li>
1763
+
1764
+ <span class='name'>frame_id</span>
1765
+
1766
+
1767
+ <span class='type'>(<tt>String</tt>)</span>
1768
+
1769
+
1770
+
1771
+ </li>
1772
+
1773
+ <li>
1774
+
1775
+ <span class='name'>url</span>
1776
+
1777
+
1778
+ <span class='type'>(<tt>String</tt>)</span>
1779
+
1780
+
1781
+
1782
+ </li>
1783
+
1784
+ </ul>
1785
+
1786
+
1787
+ </div><table class="source_code">
1788
+ <tr>
1789
+ <td>
1790
+ <pre class="lines">
1791
+
1792
+
1793
+ 282
1794
+ 283
1795
+ 284
1796
+ 285
1797
+ 286
1798
+ 287
1799
+ 288
1800
+ 289
1801
+ 290</pre>
1802
+ </td>
1803
+ <td>
1804
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 282</span>
1805
+
1806
+ <span class='kw'>def</span> <span class='id identifier rubyid_handle_frame_navigated_within_document'>handle_frame_navigated_within_document</span><span class='lparen'>(</span><span class='id identifier rubyid_frame_id'>frame_id</span><span class='comma'>,</span> <span class='id identifier rubyid_url'>url</span><span class='rparen'>)</span>
1807
+ <span class='id identifier rubyid_frame'>frame</span> <span class='op'>=</span> <span class='ivar'>@frames</span><span class='lbracket'>[</span><span class='id identifier rubyid_frame_id'>frame_id</span><span class='rbracket'>]</span>
1808
+ <span class='kw'>return</span> <span class='kw'>if</span> <span class='op'>!</span><span class='id identifier rubyid_frame'>frame</span>
1809
+ <span class='id identifier rubyid_frame'>frame</span><span class='period'>.</span><span class='id identifier rubyid_navigated_within_document'>navigated_within_document</span><span class='lparen'>(</span><span class='id identifier rubyid_url'>url</span><span class='rparen'>)</span>
1810
+ <span class='id identifier rubyid_emit_event'>emit_event</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Events.FrameManager.FrameNavigatedWithinDocument</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='id identifier rubyid_frame'>frame</span>
1811
+ <span class='id identifier rubyid_emit_event'>emit_event</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Events.FrameManager.FrameNavigated</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='id identifier rubyid_frame'>frame</span>
1812
+ <span class='id identifier rubyid_handle_frame_manager_frame_navigated_within_document'>handle_frame_manager_frame_navigated_within_document</span><span class='lparen'>(</span><span class='id identifier rubyid_frame'>frame</span><span class='rparen'>)</span>
1813
+ <span class='id identifier rubyid_handle_frame_manager_frame_navigated'>handle_frame_manager_frame_navigated</span><span class='lparen'>(</span><span class='id identifier rubyid_frame'>frame</span><span class='rparen'>)</span>
1814
+ <span class='kw'>end</span></pre>
1815
+ </td>
1816
+ </tr>
1817
+ </table>
1818
+ </div>
1819
+
1820
+ <div class="method_details ">
1821
+ <h3 class="signature " id="handle_frame_stopped_loading-instance_method">
1822
+
1823
+ #<strong>handle_frame_stopped_loading</strong>(frame_id) &#x21d2; <tt>Object</tt>
1824
+
1825
+
1826
+
1827
+
1828
+
1829
+ </h3><div class="docstring">
1830
+ <div class="discussion">
1831
+
1832
+
1833
+ </div>
1834
+ </div>
1835
+ <div class="tags">
1836
+ <p class="tag_title">Parameters:</p>
1837
+ <ul class="param">
1838
+
1839
+ <li>
1840
+
1841
+ <span class='name'>frameId</span>
1842
+
1843
+
1844
+ <span class='type'>(<tt>string</tt>)</span>
1845
+
1846
+
1847
+
1848
+ </li>
1849
+
1850
+ </ul>
1851
+
1852
+
1853
+ </div><table class="source_code">
1854
+ <tr>
1855
+ <td>
1856
+ <pre class="lines">
1857
+
1858
+
1859
+ 165
1860
+ 166
1861
+ 167
1862
+ 168
1863
+ 169
1864
+ 170</pre>
1865
+ </td>
1866
+ <td>
1867
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 165</span>
1868
+
1869
+ <span class='kw'>def</span> <span class='id identifier rubyid_handle_frame_stopped_loading'>handle_frame_stopped_loading</span><span class='lparen'>(</span><span class='id identifier rubyid_frame_id'>frame_id</span><span class='rparen'>)</span>
1870
+ <span class='id identifier rubyid_frame'>frame</span> <span class='op'>=</span> <span class='ivar'>@frames</span><span class='lbracket'>[</span><span class='id identifier rubyid_frame_id'>frame_id</span><span class='rbracket'>]</span>
1871
+ <span class='kw'>return</span> <span class='kw'>if</span> <span class='op'>!</span><span class='id identifier rubyid_frame'>frame</span>
1872
+ <span class='id identifier rubyid_frame'>frame</span><span class='period'>.</span><span class='id identifier rubyid_handle_loading_stopped'>handle_loading_stopped</span>
1873
+ <span class='id identifier rubyid_emit_event'>emit_event</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Events.FrameManager.LifecycleEvent</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='id identifier rubyid_frame'>frame</span>
1874
+ <span class='kw'>end</span></pre>
1875
+ </td>
1876
+ </tr>
1877
+ </table>
1878
+ </div>
1879
+
1880
+ <div class="method_details ">
1881
+ <h3 class="signature " id="handle_frame_tree-instance_method">
1882
+
1883
+ #<strong>handle_frame_tree</strong>(frame_tree) &#x21d2; <tt>Object</tt>
1884
+
1885
+
1886
+
1887
+
1888
+
1889
+ </h3><div class="docstring">
1890
+ <div class="discussion">
1891
+
1892
+
1893
+ </div>
1894
+ </div>
1895
+ <div class="tags">
1896
+ <p class="tag_title">Parameters:</p>
1897
+ <ul class="param">
1898
+
1899
+ <li>
1900
+
1901
+ <span class='name'>frame_tree</span>
1902
+
1903
+
1904
+ <span class='type'>(<tt>Hash</tt>)</span>
1905
+
1906
+
1907
+
1908
+ </li>
1909
+
1910
+ </ul>
1911
+
1912
+
1913
+ </div><table class="source_code">
1914
+ <tr>
1915
+ <td>
1916
+ <pre class="lines">
1917
+
1918
+
1919
+ 173
1920
+ 174
1921
+ 175
1922
+ 176
1923
+ 177
1924
+ 178
1925
+ 179
1926
+ 180
1927
+ 181
1928
+ 182
1929
+ 183</pre>
1930
+ </td>
1931
+ <td>
1932
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 173</span>
1933
+
1934
+ <span class='kw'>def</span> <span class='id identifier rubyid_handle_frame_tree'>handle_frame_tree</span><span class='lparen'>(</span><span class='id identifier rubyid_frame_tree'>frame_tree</span><span class='rparen'>)</span>
1935
+ <span class='kw'>if</span> <span class='id identifier rubyid_frame_tree'>frame_tree</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>frame</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>parentId</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span>
1936
+ <span class='id identifier rubyid_handle_frame_attached'>handle_frame_attached</span><span class='lparen'>(</span><span class='id identifier rubyid_frame_tree'>frame_tree</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>frame</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>id</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id identifier rubyid_frame_tree'>frame_tree</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>frame</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>parentId</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rparen'>)</span>
1937
+ <span class='kw'>end</span>
1938
+ <span class='id identifier rubyid_handle_frame_navigated'>handle_frame_navigated</span><span class='lparen'>(</span><span class='id identifier rubyid_frame_tree'>frame_tree</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>frame</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rparen'>)</span>
1939
+ <span class='kw'>return</span> <span class='kw'>if</span> <span class='op'>!</span><span class='id identifier rubyid_frame_tree'>frame_tree</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>childFrames</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span>
1940
+
1941
+ <span class='id identifier rubyid_frame_tree'>frame_tree</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>childFrames</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</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_child'>child</span><span class='op'>|</span>
1942
+ <span class='id identifier rubyid_handle_frame_tree'>handle_frame_tree</span><span class='lparen'>(</span><span class='id identifier rubyid_child'>child</span><span class='rparen'>)</span>
1943
+ <span class='kw'>end</span>
1944
+ <span class='kw'>end</span></pre>
1945
+ </td>
1946
+ </tr>
1947
+ </table>
1948
+ </div>
1949
+
1950
+ <div class="method_details ">
1951
+ <h3 class="signature " id="handle_lifecycle_event-instance_method">
1952
+
1953
+ #<strong>handle_lifecycle_event</strong>(event) &#x21d2; <tt>Object</tt>
1954
+
1955
+
1956
+
1957
+
1958
+
1959
+ </h3><div class="docstring">
1960
+ <div class="discussion">
1961
+
1962
+
1963
+ </div>
1964
+ </div>
1965
+ <div class="tags">
1966
+ <p class="tag_title">Parameters:</p>
1967
+ <ul class="param">
1968
+
1969
+ <li>
1970
+
1971
+ <span class='name'>event</span>
1972
+
1973
+
1974
+ <span class='type'>(<tt>Hash</tt>)</span>
1975
+
1976
+
1977
+
1978
+ </li>
1979
+
1980
+ </ul>
1981
+
1982
+
1983
+ </div><table class="source_code">
1984
+ <tr>
1985
+ <td>
1986
+ <pre class="lines">
1987
+
1988
+
1989
+ 157
1990
+ 158
1991
+ 159
1992
+ 160
1993
+ 161
1994
+ 162</pre>
1995
+ </td>
1996
+ <td>
1997
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 157</span>
1998
+
1999
+ <span class='kw'>def</span> <span class='id identifier rubyid_handle_lifecycle_event'>handle_lifecycle_event</span><span class='lparen'>(</span><span class='id identifier rubyid_event'>event</span><span class='rparen'>)</span>
2000
+ <span class='id identifier rubyid_frame'>frame</span> <span class='op'>=</span> <span class='ivar'>@frames</span><span class='lbracket'>[</span><span class='id identifier rubyid_event'>event</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>frameId</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rbracket'>]</span>
2001
+ <span class='kw'>return</span> <span class='kw'>if</span> <span class='op'>!</span><span class='id identifier rubyid_frame'>frame</span>
2002
+ <span class='id identifier rubyid_frame'>frame</span><span class='period'>.</span><span class='id identifier rubyid_handle_lifecycle_event'>handle_lifecycle_event</span><span class='lparen'>(</span><span class='id identifier rubyid_event'>event</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>loaderId</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id identifier rubyid_event'>event</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>name</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rparen'>)</span>
2003
+ <span class='id identifier rubyid_emit_event'>emit_event</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Events.FrameManager.LifecycleEvent</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='id identifier rubyid_frame'>frame</span>
2004
+ <span class='kw'>end</span></pre>
2005
+ </td>
2006
+ </tr>
2007
+ </table>
2008
+ </div>
2009
+
2010
+ <div class="method_details ">
2011
+ <h3 class="signature " id="main_frame-instance_method">
2012
+
2013
+ #<strong>main_frame</strong> &#x21d2; <tt>!<span class='object_link'><a href="Frame.html" title="Puppeteer::Frame (class)">Frame</a></span></tt>
2014
+
2015
+
2016
+
2017
+
2018
+
2019
+ </h3><div class="docstring">
2020
+ <div class="discussion">
2021
+
2022
+
2023
+ </div>
2024
+ </div>
2025
+ <div class="tags">
2026
+
2027
+ <p class="tag_title">Returns:</p>
2028
+ <ul class="return">
2029
+
2030
+ <li>
2031
+
2032
+
2033
+ <span class='type'>(<tt>!<span class='object_link'><a href="Frame.html" title="Puppeteer::Frame (class)">Frame</a></span></tt>)</span>
2034
+
2035
+
2036
+
2037
+ </li>
2038
+
2039
+ </ul>
2040
+
2041
+ </div><table class="source_code">
2042
+ <tr>
2043
+ <td>
2044
+ <pre class="lines">
2045
+
2046
+
2047
+ 191
2048
+ 192
2049
+ 193</pre>
2050
+ </td>
2051
+ <td>
2052
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 191</span>
2053
+
2054
+ <span class='kw'>def</span> <span class='id identifier rubyid_main_frame'>main_frame</span>
2055
+ <span class='ivar'>@main_frame</span>
2056
+ <span class='kw'>end</span></pre>
2057
+ </td>
2058
+ </tr>
2059
+ </table>
2060
+ </div>
2061
+
2062
+ <div class="method_details ">
2063
+ <h3 class="signature " id="navigate_frame-instance_method">
2064
+
2065
+ #<strong>navigate_frame</strong>(frame, url, referer: nil, timeout: nil, wait_until: nil) &#x21d2; <tt>Puppeteer::Response</tt>
2066
+
2067
+
2068
+
2069
+
2070
+
2071
+ </h3><div class="docstring">
2072
+ <div class="discussion">
2073
+
2074
+
2075
+ </div>
2076
+ </div>
2077
+ <div class="tags">
2078
+ <p class="tag_title">Parameters:</p>
2079
+ <ul class="param">
2080
+
2081
+ <li>
2082
+
2083
+ <span class='name'>frame</span>
2084
+
2085
+
2086
+ <span class='type'>(<tt><span class='object_link'><a href="Frame.html" title="Puppeteer::Frame (class)">Puppeteer::Frame</a></span></tt>)</span>
2087
+
2088
+
2089
+
2090
+ </li>
2091
+
2092
+ <li>
2093
+
2094
+ <span class='name'>url</span>
2095
+
2096
+
2097
+ <span class='type'>(<tt>String</tt>)</span>
2098
+
2099
+
2100
+
2101
+ </li>
2102
+
2103
+ <li>
2104
+
2105
+ <span class='name'>options</span>
2106
+
2107
+
2108
+ <span class='type'>(<tt>!{referer?: string, timeout?: number, waitUntil?: string|!Array&lt;string&gt;}=</tt>)</span>
2109
+
2110
+
2111
+
2112
+ </li>
2113
+
2114
+ </ul>
2115
+
2116
+ <p class="tag_title">Returns:</p>
2117
+ <ul class="return">
2118
+
2119
+ <li>
2120
+
2121
+
2122
+ <span class='type'>(<tt>Puppeteer::Response</tt>)</span>
2123
+
2124
+
2125
+
2126
+ </li>
2127
+
2128
+ </ul>
2129
+
2130
+ </div><table class="source_code">
2131
+ <tr>
2132
+ <td>
2133
+ <pre class="lines">
2134
+
2135
+
2136
+ 89
2137
+ 90
2138
+ 91
2139
+ 92
2140
+ 93
2141
+ 94
2142
+ 95
2143
+ 96
2144
+ 97
2145
+ 98
2146
+ 99
2147
+ 100
2148
+ 101
2149
+ 102
2150
+ 103
2151
+ 104
2152
+ 105
2153
+ 106
2154
+ 107
2155
+ 108
2156
+ 109
2157
+ 110
2158
+ 111
2159
+ 112
2160
+ 113
2161
+ 114
2162
+ 115
2163
+ 116
2164
+ 117
2165
+ 118
2166
+ 119
2167
+ 120
2168
+ 121
2169
+ 122
2170
+ 123
2171
+ 124
2172
+ 125
2173
+ 126
2174
+ 127
2175
+ 128
2176
+ 129
2177
+ 130
2178
+ 131
2179
+ 132</pre>
2180
+ </td>
2181
+ <td>
2182
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 89</span>
2183
+
2184
+ <span class='kw'>def</span> <span class='id identifier rubyid_navigate_frame'>navigate_frame</span><span class='lparen'>(</span><span class='id identifier rubyid_frame'>frame</span><span class='comma'>,</span> <span class='id identifier rubyid_url'>url</span><span class='comma'>,</span> <span class='label'>referer:</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='label'>timeout:</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='label'>wait_until:</span> <span class='kw'>nil</span><span class='rparen'>)</span>
2185
+ <span class='id identifier rubyid_assert_no_legacy_navigation_options'>assert_no_legacy_navigation_options</span><span class='lparen'>(</span><span class='label'>wait_until:</span> <span class='id identifier rubyid_wait_until'>wait_until</span><span class='rparen'>)</span>
2186
+
2187
+ <span class='id identifier rubyid_navigate_params'>navigate_params</span> <span class='op'>=</span> <span class='lbrace'>{</span>
2188
+ <span class='label'>url:</span> <span class='id identifier rubyid_url'>url</span><span class='comma'>,</span>
2189
+ <span class='label'>referer:</span> <span class='id identifier rubyid_referer'>referer</span> <span class='op'>||</span> <span class='ivar'>@network_manager</span><span class='period'>.</span><span class='id identifier rubyid_extra_http_headers'>extra_http_headers</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>referer</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='comma'>,</span>
2190
+ <span class='label'>frameId:</span> <span class='id identifier rubyid_frame'>frame</span><span class='period'>.</span><span class='id identifier rubyid_id'>id</span><span class='comma'>,</span>
2191
+ <span class='rbrace'>}</span><span class='period'>.</span><span class='id identifier rubyid_compact'>compact</span>
2192
+ <span class='id identifier rubyid_option_wait_until'>option_wait_until</span> <span class='op'>=</span> <span class='id identifier rubyid_wait_until'>wait_until</span> <span class='op'>||</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>load</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span>
2193
+ <span class='id identifier rubyid_option_timeout'>option_timeout</span> <span class='op'>=</span> <span class='id identifier rubyid_timeout'>timeout</span> <span class='op'>||</span> <span class='ivar'>@timeout_settings</span><span class='period'>.</span><span class='id identifier rubyid_navigation_timeout'>navigation_timeout</span>
2194
+
2195
+ <span class='id identifier rubyid_watcher'>watcher</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="../Puppeteer.html" title="Puppeteer (class)">Puppeteer</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="LifecycleWatcher.html" title="Puppeteer::LifecycleWatcher (class)">LifecycleWatcher</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="LifecycleWatcher.html#initialize-instance_method" title="Puppeteer::LifecycleWatcher#initialize (method)">new</a></span></span><span class='lparen'>(</span><span class='kw'>self</span><span class='comma'>,</span> <span class='id identifier rubyid_frame'>frame</span><span class='comma'>,</span> <span class='id identifier rubyid_option_wait_until'>option_wait_until</span><span class='comma'>,</span> <span class='id identifier rubyid_option_timeout'>option_timeout</span><span class='rparen'>)</span>
2196
+ <span class='id identifier rubyid_ensure_new_document_navigation'>ensure_new_document_navigation</span> <span class='op'>=</span> <span class='kw'>false</span>
2197
+
2198
+ <span class='kw'>begin</span>
2199
+ <span class='id identifier rubyid_navigate'>navigate</span> <span class='op'>=</span> <span class='id identifier rubyid_future'><span class='object_link'><a href="ConcurrentRubyUtils.html#future-instance_method" title="Puppeteer::ConcurrentRubyUtils#future (method)">future</a></span></span> <span class='kw'>do</span>
2200
+ <span class='id identifier rubyid_result'>result</span> <span class='op'>=</span> <span class='ivar'>@client</span><span class='period'>.</span><span class='id identifier rubyid_send_message'>send_message</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Page.navigate</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='id identifier rubyid_navigate_params'>navigate_params</span><span class='rparen'>)</span>
2201
+ <span class='id identifier rubyid_loader_id'>loader_id</span> <span class='op'>=</span> <span class='id identifier rubyid_result'>result</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>loaderId</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span>
2202
+ <span class='id identifier rubyid_ensure_new_document_navigation'>ensure_new_document_navigation</span> <span class='op'>=</span> <span class='op'>!</span><span class='op'>!</span><span class='id identifier rubyid_loader_id'>loader_id</span>
2203
+ <span class='kw'>if</span> <span class='id identifier rubyid_result'>result</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>errorText</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span>
2204
+ <span class='id identifier rubyid_raise'>raise</span> <span class='const'><span class='object_link'><a href="FrameManager/NavigationError.html" title="Puppeteer::FrameManager::NavigationError (class)">NavigationError</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="#initialize-instance_method" title="Puppeteer::FrameManager#initialize (method)">new</a></span></span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='embexpr_beg'>#{</span><span class='id identifier rubyid_result'>result</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>errorText</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='embexpr_end'>}</span><span class='tstring_content'> at </span><span class='embexpr_beg'>#{</span><span class='id identifier rubyid_url'>url</span><span class='embexpr_end'>}</span><span class='tstring_end'>&quot;</span></span><span class='rparen'>)</span>
2205
+ <span class='kw'>end</span>
2206
+ <span class='kw'>end</span>
2207
+ <span class='id identifier rubyid_await_any'><span class='object_link'><a href="ConcurrentRubyUtils.html#await_any-instance_method" title="Puppeteer::ConcurrentRubyUtils#await_any (method)">await_any</a></span></span><span class='lparen'>(</span>
2208
+ <span class='id identifier rubyid_navigate'>navigate</span><span class='comma'>,</span>
2209
+ <span class='id identifier rubyid_watcher'>watcher</span><span class='period'>.</span><span class='id identifier rubyid_timeout_or_termination_promise'>timeout_or_termination_promise</span><span class='comma'>,</span>
2210
+ <span class='rparen'>)</span>
2211
+
2212
+ <span class='id identifier rubyid_document_navigation_promise'>document_navigation_promise</span> <span class='op'>=</span>
2213
+ <span class='kw'>if</span> <span class='id identifier rubyid_ensure_new_document_navigation'>ensure_new_document_navigation</span>
2214
+ <span class='id identifier rubyid_watcher'>watcher</span><span class='period'>.</span><span class='id identifier rubyid_new_document_navigation_promise'>new_document_navigation_promise</span>
2215
+ <span class='kw'>else</span>
2216
+ <span class='id identifier rubyid_watcher'>watcher</span><span class='period'>.</span><span class='id identifier rubyid_same_document_navigation_promise'>same_document_navigation_promise</span>
2217
+ <span class='kw'>end</span>
2218
+ <span class='id identifier rubyid_await_any'><span class='object_link'><a href="ConcurrentRubyUtils.html#await_any-instance_method" title="Puppeteer::ConcurrentRubyUtils#await_any (method)">await_any</a></span></span><span class='lparen'>(</span>
2219
+ <span class='id identifier rubyid_document_navigation_promise'>document_navigation_promise</span><span class='comma'>,</span>
2220
+ <span class='id identifier rubyid_watcher'>watcher</span><span class='period'>.</span><span class='id identifier rubyid_timeout_or_termination_promise'>timeout_or_termination_promise</span><span class='comma'>,</span>
2221
+ <span class='rparen'>)</span>
2222
+ <span class='kw'>ensure</span>
2223
+ <span class='id identifier rubyid_watcher'>watcher</span><span class='period'>.</span><span class='id identifier rubyid_dispose'>dispose</span>
2224
+ <span class='kw'>end</span>
2225
+
2226
+ <span class='id identifier rubyid_watcher'>watcher</span><span class='period'>.</span><span class='id identifier rubyid_navigation_response'>navigation_response</span>
2227
+ <span class='kw'>end</span></pre>
2228
+ </td>
2229
+ </tr>
2230
+ </table>
2231
+ </div>
2232
+
2233
+ <div class="method_details ">
2234
+ <h3 class="signature " id="page-instance_method">
2235
+
2236
+ #<strong>page</strong> &#x21d2; <tt>!<span class='object_link'><a href="../Puppeteer.html" title="Puppeteer (class)">Puppeteer</a></span>.<span class='object_link'><a href="Page.html" title="Puppeteer::Page (class)">Page</a></span></tt>
2237
+
2238
+
2239
+
2240
+
2241
+
2242
+ </h3><div class="docstring">
2243
+ <div class="discussion">
2244
+
2245
+
2246
+ </div>
2247
+ </div>
2248
+ <div class="tags">
2249
+
2250
+ <p class="tag_title">Returns:</p>
2251
+ <ul class="return">
2252
+
2253
+ <li>
2254
+
2255
+
2256
+ <span class='type'>(<tt>!<span class='object_link'><a href="../Puppeteer.html" title="Puppeteer (class)">Puppeteer</a></span>.<span class='object_link'><a href="Page.html" title="Puppeteer::Page (class)">Page</a></span></tt>)</span>
2257
+
2258
+
2259
+
2260
+ </li>
2261
+
2262
+ </ul>
2263
+
2264
+ </div><table class="source_code">
2265
+ <tr>
2266
+ <td>
2267
+ <pre class="lines">
2268
+
2269
+
2270
+ 186
2271
+ 187
2272
+ 188</pre>
2273
+ </td>
2274
+ <td>
2275
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 186</span>
2276
+
2277
+ <span class='kw'>def</span> <span class='id identifier rubyid_page'>page</span>
2278
+ <span class='ivar'>@page</span>
2279
+ <span class='kw'>end</span></pre>
2280
+ </td>
2281
+ </tr>
2282
+ </table>
2283
+ </div>
2284
+
2285
+ <div class="method_details ">
2286
+ <h3 class="signature " id="wait_for_frame_navigation-instance_method">
2287
+
2288
+ #<strong>wait_for_frame_navigation</strong>(frame, timeout: nil, wait_until: nil) &#x21d2; <tt>Puppeteer::Response</tt>
2289
+
2290
+
2291
+
2292
+
2293
+
2294
+ </h3><div class="docstring">
2295
+ <div class="discussion">
2296
+
2297
+
2298
+ </div>
2299
+ </div>
2300
+ <div class="tags">
2301
+ <p class="tag_title">Parameters:</p>
2302
+ <ul class="param">
2303
+
2304
+ <li>
2305
+
2306
+ <span class='name'>timeout</span>
2307
+
2308
+
2309
+ <span class='type'>(<tt>number|nil</tt>)</span>
2310
+
2311
+
2312
+ <em class="default">(defaults to: <tt>nil</tt>)</em>
2313
+
2314
+
2315
+ </li>
2316
+
2317
+ <li>
2318
+
2319
+ <span class='name'>wait_until</span>
2320
+
2321
+
2322
+ <span class='type'>(<tt>string|nil</tt>)</span>
2323
+
2324
+
2325
+ <em class="default">(defaults to: <tt>nil</tt>)</em>
2326
+
2327
+
2328
+ &mdash;
2329
+ <div class='inline'>
2330
+ <p>&#39;load&#39; | &#39;domcontentloaded&#39; | &#39;networkidle0&#39; | &#39;networkidle2&#39;</p>
2331
+ </div>
2332
+
2333
+ </li>
2334
+
2335
+ </ul>
2336
+
2337
+ <p class="tag_title">Returns:</p>
2338
+ <ul class="return">
2339
+
2340
+ <li>
2341
+
2342
+
2343
+ <span class='type'>(<tt>Puppeteer::Response</tt>)</span>
2344
+
2345
+
2346
+
2347
+ </li>
2348
+
2349
+ </ul>
2350
+
2351
+ </div><table class="source_code">
2352
+ <tr>
2353
+ <td>
2354
+ <pre class="lines">
2355
+
2356
+
2357
+ 137
2358
+ 138
2359
+ 139
2360
+ 140
2361
+ 141
2362
+ 142
2363
+ 143
2364
+ 144
2365
+ 145
2366
+ 146
2367
+ 147
2368
+ 148
2369
+ 149
2370
+ 150
2371
+ 151
2372
+ 152
2373
+ 153
2374
+ 154</pre>
2375
+ </td>
2376
+ <td>
2377
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/frame_manager.rb', line 137</span>
2378
+
2379
+ <span class='kw'>def</span> <span class='id identifier rubyid_wait_for_frame_navigation'>wait_for_frame_navigation</span><span class='lparen'>(</span><span class='id identifier rubyid_frame'>frame</span><span class='comma'>,</span> <span class='label'>timeout:</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='label'>wait_until:</span> <span class='kw'>nil</span><span class='rparen'>)</span>
2380
+ <span class='id identifier rubyid_assert_no_legacy_navigation_options'>assert_no_legacy_navigation_options</span><span class='lparen'>(</span><span class='label'>wait_until:</span> <span class='id identifier rubyid_wait_until'>wait_until</span><span class='rparen'>)</span>
2381
+
2382
+ <span class='id identifier rubyid_option_wait_until'>option_wait_until</span> <span class='op'>=</span> <span class='id identifier rubyid_wait_until'>wait_until</span> <span class='op'>||</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>load</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span>
2383
+ <span class='id identifier rubyid_option_timeout'>option_timeout</span> <span class='op'>=</span> <span class='id identifier rubyid_timeout'>timeout</span> <span class='op'>||</span> <span class='ivar'>@timeout_settings</span><span class='period'>.</span><span class='id identifier rubyid_navigation_timeout'>navigation_timeout</span>
2384
+ <span class='id identifier rubyid_watcher'>watcher</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="../Puppeteer.html" title="Puppeteer (class)">Puppeteer</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="LifecycleWatcher.html" title="Puppeteer::LifecycleWatcher (class)">LifecycleWatcher</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="LifecycleWatcher.html#initialize-instance_method" title="Puppeteer::LifecycleWatcher#initialize (method)">new</a></span></span><span class='lparen'>(</span><span class='kw'>self</span><span class='comma'>,</span> <span class='id identifier rubyid_frame'>frame</span><span class='comma'>,</span> <span class='id identifier rubyid_option_wait_until'>option_wait_until</span><span class='comma'>,</span> <span class='id identifier rubyid_option_timeout'>option_timeout</span><span class='rparen'>)</span>
2385
+ <span class='kw'>begin</span>
2386
+ <span class='id identifier rubyid_await_any'><span class='object_link'><a href="ConcurrentRubyUtils.html#await_any-instance_method" title="Puppeteer::ConcurrentRubyUtils#await_any (method)">await_any</a></span></span><span class='lparen'>(</span>
2387
+ <span class='id identifier rubyid_watcher'>watcher</span><span class='period'>.</span><span class='id identifier rubyid_timeout_or_termination_promise'>timeout_or_termination_promise</span><span class='comma'>,</span>
2388
+ <span class='id identifier rubyid_watcher'>watcher</span><span class='period'>.</span><span class='id identifier rubyid_same_document_navigation_promise'>same_document_navigation_promise</span><span class='comma'>,</span>
2389
+ <span class='id identifier rubyid_watcher'>watcher</span><span class='period'>.</span><span class='id identifier rubyid_new_document_navigation_promise'>new_document_navigation_promise</span><span class='comma'>,</span>
2390
+ <span class='rparen'>)</span>
2391
+ <span class='kw'>ensure</span>
2392
+ <span class='id identifier rubyid_watcher'>watcher</span><span class='period'>.</span><span class='id identifier rubyid_dispose'>dispose</span>
2393
+ <span class='kw'>end</span>
2394
+
2395
+ <span class='id identifier rubyid_watcher'>watcher</span><span class='period'>.</span><span class='id identifier rubyid_navigation_response'>navigation_response</span>
2396
+ <span class='kw'>end</span></pre>
2397
+ </td>
2398
+ </tr>
2399
+ </table>
2400
+ </div>
2401
+
2402
+ </div>
2403
+
2404
+ </div>
2405
+
2406
+ <div id="footer">
2407
+ Generated on Sun Apr 26 15:52:57 2020 by
2408
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
2409
+ 0.9.24 (ruby-2.6.3).
2410
+ </div>
2411
+
2412
+ </div>
2413
+ </body>
2414
+ </html>