puppeteer-ruby 0.0.9 → 0.0.10

Sign up to get free protection for your applications and to get access to all the features.
Files changed (101) hide show
  1. checksums.yaml +4 -4
  2. data/docs/Puppeteer.html +3 -3
  3. data/docs/Puppeteer/AsyncAwaitBehavior.html +1 -1
  4. data/docs/Puppeteer/Browser.html +2 -2
  5. data/docs/Puppeteer/BrowserContext.html +1 -1
  6. data/docs/Puppeteer/BrowserFetcher.html +1 -1
  7. data/docs/Puppeteer/BrowserRunner.html +1 -1
  8. data/docs/Puppeteer/BrowserRunner/BrowserProcess.html +1 -1
  9. data/docs/Puppeteer/CDPSession.html +1 -1
  10. data/docs/Puppeteer/CDPSession/Error.html +1 -1
  11. data/docs/Puppeteer/ConcurrentRubyUtils.html +1 -1
  12. data/docs/Puppeteer/Connection.html +1 -1
  13. data/docs/Puppeteer/Connection/MessageCallback.html +1 -1
  14. data/docs/Puppeteer/Connection/ProtocolError.html +1 -1
  15. data/docs/Puppeteer/Connection/RequestDebugPrinter.html +1 -1
  16. data/docs/Puppeteer/Connection/ResponseDebugPrinter.html +1 -1
  17. data/docs/Puppeteer/ConsoleMessage.html +1 -1
  18. data/docs/Puppeteer/ConsoleMessage/Location.html +1 -1
  19. data/docs/Puppeteer/DOMWorld.html +1 -1
  20. data/docs/Puppeteer/DOMWorld/DetachedError.html +1 -1
  21. data/docs/Puppeteer/DOMWorld/DocumentEvaluationError.html +1 -1
  22. data/docs/Puppeteer/DebugPrint.html +1 -1
  23. data/docs/Puppeteer/Device.html +1 -1
  24. data/docs/Puppeteer/Devices.html +1 -1
  25. data/docs/Puppeteer/ElementHandle.html +525 -207
  26. data/docs/Puppeteer/ElementHandle/ElementNotFoundError.html +5 -5
  27. data/docs/Puppeteer/ElementHandle/ElementNotVisibleError.html +5 -5
  28. data/docs/Puppeteer/ElementHandle/Point.html +40 -29
  29. data/docs/Puppeteer/ElementHandle/ScrollIntoViewError.html +1 -1
  30. data/docs/Puppeteer/EmulationManager.html +1 -1
  31. data/docs/Puppeteer/EventCallbackable.html +1 -1
  32. data/docs/Puppeteer/EventCallbackable/EventListeners.html +1 -1
  33. data/docs/Puppeteer/ExecutionContext.html +1 -1
  34. data/docs/Puppeteer/ExecutionContext/EvaluationError.html +1 -1
  35. data/docs/Puppeteer/ExecutionContext/JavaScriptExpression.html +1 -1
  36. data/docs/Puppeteer/ExecutionContext/JavaScriptFunction.html +1 -1
  37. data/docs/Puppeteer/FileChooser.html +1 -1
  38. data/docs/Puppeteer/Frame.html +1 -1
  39. data/docs/Puppeteer/FrameManager.html +1 -1
  40. data/docs/Puppeteer/FrameManager/NavigationError.html +1 -1
  41. data/docs/Puppeteer/IfPresent.html +1 -1
  42. data/docs/Puppeteer/JSHandle.html +1 -1
  43. data/docs/Puppeteer/Keyboard.html +1 -1
  44. data/docs/Puppeteer/Keyboard/KeyDefinition.html +1 -1
  45. data/docs/Puppeteer/Keyboard/KeyDescription.html +1 -1
  46. data/docs/Puppeteer/Launcher.html +1 -1
  47. data/docs/Puppeteer/Launcher/Base.html +1 -1
  48. data/docs/Puppeteer/Launcher/Base/ExecutablePathNotFound.html +1 -1
  49. data/docs/Puppeteer/Launcher/BrowserOptions.html +1 -1
  50. data/docs/Puppeteer/Launcher/Chrome.html +1 -1
  51. data/docs/Puppeteer/Launcher/Chrome/DefaultArgs.html +1 -1
  52. data/docs/Puppeteer/Launcher/ChromeArgOptions.html +1 -1
  53. data/docs/Puppeteer/Launcher/LaunchOptions.html +1 -1
  54. data/docs/Puppeteer/LifecycleWatcher.html +1 -1
  55. data/docs/Puppeteer/LifecycleWatcher/ExpectedLifecycle.html +1 -1
  56. data/docs/Puppeteer/LifecycleWatcher/FrameDetachedError.html +1 -1
  57. data/docs/Puppeteer/LifecycleWatcher/TerminatedError.html +1 -1
  58. data/docs/Puppeteer/Mouse.html +1 -1
  59. data/docs/Puppeteer/Mouse/Button.html +1 -1
  60. data/docs/Puppeteer/NetworkManager.html +1 -1
  61. data/docs/Puppeteer/NetworkManager/Credentials.html +1 -1
  62. data/docs/Puppeteer/Page.html +2 -2
  63. data/docs/Puppeteer/Page/FileChooserTimeoutError.html +1 -1
  64. data/docs/Puppeteer/Page/ScreenshotOptions.html +1 -1
  65. data/docs/Puppeteer/Page/ScriptTag.html +1 -1
  66. data/docs/Puppeteer/Page/StyleTag.html +1 -1
  67. data/docs/Puppeteer/Page/TargetCrashedError.html +1 -1
  68. data/docs/Puppeteer/RemoteObject.html +110 -39
  69. data/docs/Puppeteer/Target.html +138 -116
  70. data/docs/Puppeteer/Target/InitializeFailure.html +1 -1
  71. data/docs/Puppeteer/Target/TargetInfo.html +1 -1
  72. data/docs/Puppeteer/TimeoutError.html +2 -2
  73. data/docs/Puppeteer/TimeoutSettings.html +1 -1
  74. data/docs/Puppeteer/TouchScreen.html +1 -1
  75. data/docs/Puppeteer/Viewport.html +81 -1
  76. data/docs/Puppeteer/WaitTask.html +1 -1
  77. data/docs/Puppeteer/WaitTask/TerminatedError.html +1 -1
  78. data/docs/Puppeteer/WaitTask/TimeoutError.html +1 -1
  79. data/docs/Puppeteer/WebSocket.html +26 -26
  80. data/docs/Puppeteer/WebSocket/DriverImpl.html +1 -1
  81. data/docs/Puppeteer/WebSocketTransport.html +2 -2
  82. data/docs/_index.html +26 -12
  83. data/docs/class_list.html +1 -1
  84. data/docs/file.README.html +1 -1
  85. data/docs/index.html +1 -1
  86. data/docs/method_list.html +675 -571
  87. data/docs/top-level-namespace.html +1 -1
  88. data/lib/puppeteer/browser.rb +1 -1
  89. data/lib/puppeteer/element_handle.rb +66 -108
  90. data/lib/puppeteer/element_handle/bounding_box.rb +12 -0
  91. data/lib/puppeteer/element_handle/box_model.rb +19 -0
  92. data/lib/puppeteer/element_handle/point.rb +26 -0
  93. data/lib/puppeteer/errors.rb +1 -3
  94. data/lib/puppeteer/page.rb +1 -1
  95. data/lib/puppeteer/remote_object.rb +9 -0
  96. data/lib/puppeteer/target.rb +9 -12
  97. data/lib/puppeteer/version.rb +1 -1
  98. data/lib/puppeteer/viewport.rb +18 -0
  99. data/lib/puppeteer/web_socket.rb +3 -1
  100. data/lib/puppeteer/web_socket_transport.rb +1 -1
  101. metadata +5 -2
@@ -196,7 +196,7 @@
196
196
  </div>
197
197
 
198
198
  <div id="footer">
199
- Generated on Tue Jun 9 00:13:41 2020 by
199
+ Generated on Fri Jun 12 12:38:35 2020 by
200
200
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
201
201
  0.9.24 (ruby-2.6.3).
202
202
  </div>
@@ -114,7 +114,7 @@
114
114
  </div>
115
115
 
116
116
  <div id="footer">
117
- Generated on Tue Jun 9 00:13:41 2020 by
117
+ Generated on Fri Jun 12 12:38:35 2020 by
118
118
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
119
119
  0.9.24 (ruby-2.6.3).
120
120
  </div>
@@ -1095,7 +1095,7 @@
1095
1095
  </div>
1096
1096
 
1097
1097
  <div id="footer">
1098
- Generated on Tue Jun 9 00:13:39 2020 by
1098
+ Generated on Fri Jun 12 12:38:33 2020 by
1099
1099
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
1100
1100
  0.9.24 (ruby-2.6.3).
1101
1101
  </div>
@@ -126,7 +126,7 @@
126
126
  </div>
127
127
 
128
128
  <div id="footer">
129
- Generated on Tue Jun 9 00:13:39 2020 by
129
+ Generated on Fri Jun 12 12:38:32 2020 by
130
130
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
131
131
  0.9.24 (ruby-2.6.3).
132
132
  </div>
@@ -891,7 +891,7 @@
891
891
  </div>
892
892
 
893
893
  <div id="footer">
894
- Generated on Tue Jun 9 00:13:41 2020 by
894
+ Generated on Fri Jun 12 12:38:35 2020 by
895
895
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
896
896
  0.9.24 (ruby-2.6.3).
897
897
  </div>
@@ -375,7 +375,7 @@
375
375
  </div>
376
376
 
377
377
  <div id="footer">
378
- Generated on Tue Jun 9 00:13:41 2020 by
378
+ Generated on Fri Jun 12 12:38:35 2020 by
379
379
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
380
380
  0.9.24 (ruby-2.6.3).
381
381
  </div>
@@ -1902,7 +1902,7 @@
1902
1902
  <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.fileChooserOpened</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>
1903
1903
  <span class='id identifier rubyid_handle_file_chooser'>handle_file_chooser</span><span class='lparen'>(</span><span class='id identifier rubyid_event'>event</span><span class='rparen'>)</span>
1904
1904
  <span class='kw'>end</span>
1905
- <span class='ivar'>@target</span><span class='period'>.</span><span class='id identifier rubyid_on_close'>on_close</span> <span class='kw'>do</span>
1905
+ <span class='ivar'>@target</span><span class='period'>.</span><span class='id identifier rubyid_is_closed_promise'>is_closed_promise</span><span class='period'>.</span><span class='id identifier rubyid_then'>then</span> <span class='kw'>do</span>
1906
1906
  <span class='id identifier rubyid_emit_event'>emit_event</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Events.Page.Close</span><span class='tstring_end'>&#39;</span></span>
1907
1907
  <span class='ivar'>@closed</span> <span class='op'>=</span> <span class='kw'>true</span>
1908
1908
  <span class='kw'>end</span>
@@ -5960,7 +5960,7 @@ await this._client.send('Emulation.setGeolocationOverride', latitude, ac
5960
5960
  </div>
5961
5961
 
5962
5962
  <div id="footer">
5963
- Generated on Tue Jun 9 00:13:39 2020 by
5963
+ Generated on Fri Jun 12 12:38:33 2020 by
5964
5964
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
5965
5965
  0.9.24 (ruby-2.6.3).
5966
5966
  </div>
@@ -196,7 +196,7 @@
196
196
  </div>
197
197
 
198
198
  <div id="footer">
199
- Generated on Tue Jun 9 00:13:39 2020 by
199
+ Generated on Fri Jun 12 12:38:33 2020 by
200
200
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
201
201
  0.9.24 (ruby-2.6.3).
202
202
  </div>
@@ -835,7 +835,7 @@
835
835
  </div>
836
836
 
837
837
  <div id="footer">
838
- Generated on Tue Jun 9 00:13:41 2020 by
838
+ Generated on Fri Jun 12 12:38:35 2020 by
839
839
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
840
840
  0.9.24 (ruby-2.6.3).
841
841
  </div>
@@ -545,7 +545,7 @@ if (items.length)
545
545
  </div>
546
546
 
547
547
  <div id="footer">
548
- Generated on Tue Jun 9 00:13:39 2020 by
548
+ Generated on Fri Jun 12 12:38:33 2020 by
549
549
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
550
550
  0.9.24 (ruby-2.6.3).
551
551
  </div>
@@ -438,7 +438,7 @@
438
438
  </div>
439
439
 
440
440
  <div id="footer">
441
- Generated on Tue Jun 9 00:13:39 2020 by
441
+ Generated on Fri Jun 12 12:38:33 2020 by
442
442
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
443
443
  0.9.24 (ruby-2.6.3).
444
444
  </div>
@@ -114,7 +114,7 @@
114
114
  </div>
115
115
 
116
116
  <div id="footer">
117
- Generated on Tue Jun 9 00:13:39 2020 by
117
+ Generated on Fri Jun 12 12:38:33 2020 by
118
118
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
119
119
  0.9.24 (ruby-2.6.3).
120
120
  </div>
@@ -167,6 +167,30 @@
167
167
  <li class="public ">
168
168
  <span class="summary_signature">
169
169
 
170
+ <a href="#box_model-instance_method" title="#box_model (instance method)">#<strong>box_model</strong>(client) &#x21d2; Object </a>
171
+
172
+
173
+
174
+ </span>
175
+
176
+
177
+
178
+
179
+
180
+
181
+
182
+
183
+
184
+ <span class="summary_desc"><div class='inline'>
185
+ <p>used in ElementHandle#_box_model.</p>
186
+ </div></span>
187
+
188
+ </li>
189
+
190
+
191
+ <li class="public ">
192
+ <span class="summary_signature">
193
+
170
194
  <a href="#content_quads-instance_method" title="#content_quads (instance method)">#<strong>content_quads</strong>(client) &#x21d2; Object </a>
171
195
 
172
196
 
@@ -511,7 +535,54 @@
511
535
 
512
536
 
513
537
  <div class="method_details first">
514
- <h3 class="signature first" id="content_quads-instance_method">
538
+ <h3 class="signature first" id="box_model-instance_method">
539
+
540
+ #<strong>box_model</strong>(client) &#x21d2; <tt>Object</tt>
541
+
542
+
543
+
544
+
545
+
546
+ </h3><div class="docstring">
547
+ <div class="discussion">
548
+
549
+ <p>used in ElementHandle#_box_model</p>
550
+
551
+
552
+ </div>
553
+ </div>
554
+ <div class="tags">
555
+
556
+
557
+ </div><table class="source_code">
558
+ <tr>
559
+ <td>
560
+ <pre class="lines">
561
+
562
+
563
+ 66
564
+ 67
565
+ 68
566
+ 69
567
+ 70
568
+ 71</pre>
569
+ </td>
570
+ <td>
571
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/remote_object.rb', line 66</span>
572
+
573
+ <span class='kw'>def</span> <span class='id identifier rubyid_box_model'>box_model</span><span class='lparen'>(</span><span class='id identifier rubyid_client'>client</span><span class='rparen'>)</span>
574
+ <span class='id identifier rubyid_client'>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'>DOM.getBoxModel</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='label'>objectId:</span> <span class='ivar'>@object_id</span><span class='rparen'>)</span>
575
+ <span class='kw'>rescue</span> <span class='op'>=&gt;</span> <span class='id identifier rubyid_err'>err</span>
576
+ <span class='id identifier rubyid_debug_puts'>debug_puts</span><span class='lparen'>(</span><span class='id identifier rubyid_err'>err</span><span class='rparen'>)</span>
577
+ <span class='kw'>nil</span>
578
+ <span class='kw'>end</span></pre>
579
+ </td>
580
+ </tr>
581
+ </table>
582
+ </div>
583
+
584
+ <div class="method_details ">
585
+ <h3 class="signature " id="content_quads-instance_method">
515
586
 
516
587
  #<strong>content_quads</strong>(client) &#x21d2; <tt>Object</tt>
517
588
 
@@ -566,15 +637,6 @@
566
637
  <pre class="lines">
567
638
 
568
639
 
569
- 110
570
- 111
571
- 112
572
- 113
573
- 114
574
- 115
575
- 116
576
- 117
577
- 118
578
640
  119
579
641
  120
580
642
  121
@@ -584,10 +646,19 @@
584
646
  125
585
647
  126
586
648
  127
587
- 128</pre>
649
+ 128
650
+ 129
651
+ 130
652
+ 131
653
+ 132
654
+ 133
655
+ 134
656
+ 135
657
+ 136
658
+ 137</pre>
588
659
  </td>
589
660
  <td>
590
- <pre class="code"><span class="info file"># File 'lib/puppeteer/remote_object.rb', line 110</span>
661
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/remote_object.rb', line 119</span>
591
662
 
592
663
  <span class='kw'>def</span> <span class='id identifier rubyid_converted_arg'>converted_arg</span>
593
664
  <span class='comment'># ported logic from ExecutionContext#convertArgument
@@ -844,24 +915,24 @@
844
915
  <pre class="lines">
845
916
 
846
917
 
847
- 89
848
- 90
849
- 91
850
- 92
851
- 93
852
- 94
853
- 95
854
- 96
855
- 97
856
918
  98
857
919
  99
858
920
  100
859
921
  101
860
922
  102
861
- 103</pre>
923
+ 103
924
+ 104
925
+ 105
926
+ 106
927
+ 107
928
+ 108
929
+ 109
930
+ 110
931
+ 111
932
+ 112</pre>
862
933
  </td>
863
934
  <td>
864
- <pre class="code"><span class="info file"># File 'lib/puppeteer/remote_object.rb', line 89</span>
935
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/remote_object.rb', line 98</span>
865
936
 
866
937
  <span class='kw'>def</span> <span class='id identifier rubyid_release'>release</span><span class='lparen'>(</span><span class='id identifier rubyid_client'>client</span><span class='rparen'>)</span>
867
938
  <span class='kw'>return</span> <span class='kw'>unless</span> <span class='ivar'>@object_id</span>
@@ -909,12 +980,12 @@
909
980
  <pre class="lines">
910
981
 
911
982
 
912
- 131
913
- 132
914
- 133</pre>
983
+ 140
984
+ 141
985
+ 142</pre>
915
986
  </td>
916
987
  <td>
917
- <pre class="code"><span class="info file"># File 'lib/puppeteer/remote_object.rb', line 131</span>
988
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/remote_object.rb', line 140</span>
918
989
 
919
990
  <span class='kw'>def</span> <span class='id identifier rubyid_set_file_input_files'>set_file_input_files</span><span class='lparen'>(</span><span class='id identifier rubyid_client'>client</span><span class='comma'>,</span> <span class='id identifier rubyid_files'>files</span><span class='comma'>,</span> <span class='id identifier rubyid_backend_node_id'>backend_node_id</span><span class='rparen'>)</span>
920
991
  <span class='id identifier rubyid_client'>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'>DOM.setFileInputFiles</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='label'>objectId:</span> <span class='ivar'>@object_id</span><span class='comma'>,</span> <span class='label'>files:</span> <span class='id identifier rubyid_files'>files</span><span class='comma'>,</span> <span class='label'>backendNodeId:</span> <span class='id identifier rubyid_backend_node_id'>backend_node_id</span><span class='rparen'>)</span>
@@ -950,15 +1021,6 @@
950
1021
  <pre class="lines">
951
1022
 
952
1023
 
953
- 66
954
- 67
955
- 68
956
- 69
957
- 70
958
- 71
959
- 72
960
- 73
961
- 74
962
1024
  75
963
1025
  76
964
1026
  77
@@ -970,10 +1032,19 @@
970
1032
  83
971
1033
  84
972
1034
  85
973
- 86</pre>
1035
+ 86
1036
+ 87
1037
+ 88
1038
+ 89
1039
+ 90
1040
+ 91
1041
+ 92
1042
+ 93
1043
+ 94
1044
+ 95</pre>
974
1045
  </td>
975
1046
  <td>
976
- <pre class="code"><span class="info file"># File 'lib/puppeteer/remote_object.rb', line 66</span>
1047
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/remote_object.rb', line 75</span>
977
1048
 
978
1049
  <span class='kw'>def</span> <span class='id identifier rubyid_value'>value</span>
979
1050
  <span class='kw'>if</span> <span class='ivar'>@unserializable_value</span>
@@ -1006,7 +1077,7 @@
1006
1077
  </div>
1007
1078
 
1008
1079
  <div id="footer">
1009
- Generated on Tue Jun 9 00:13:40 2020 by
1080
+ Generated on Fri Jun 12 12:38:34 2020 by
1010
1081
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
1011
1082
  0.9.24 (ruby-2.6.3).
1012
1083
  </div>
@@ -153,6 +153,35 @@
153
153
  <p>Returns the value of attribute initialized_promise.</p>
154
154
  </div></span>
155
155
 
156
+ </li>
157
+
158
+
159
+ <li class="public ">
160
+ <span class="summary_signature">
161
+
162
+ <a href="#is_closed_promise-instance_method" title="#is_closed_promise (instance method)">#<strong>is_closed_promise</strong> &#x21d2; Object </a>
163
+
164
+
165
+
166
+ </span>
167
+
168
+
169
+
170
+
171
+ <span class="note title readonly">readonly</span>
172
+
173
+
174
+
175
+
176
+
177
+
178
+
179
+
180
+
181
+ <span class="summary_desc"><div class='inline'>
182
+ <p>Returns the value of attribute is_closed_promise.</p>
183
+ </div></span>
184
+
156
185
  </li>
157
186
 
158
187
 
@@ -245,7 +274,7 @@
245
274
  <li class="public ">
246
275
  <span class="summary_signature">
247
276
 
248
- <a href="#create_cdp_session-instance_method" title="#create_cdp_session (instance method)">#<strong>create_cdp_session</strong> &#x21d2; Object </a>
277
+ <a href="#closed_callback-instance_method" title="#closed_callback (instance method)">#<strong>closed_callback</strong> &#x21d2; Object </a>
249
278
 
250
279
 
251
280
 
@@ -267,7 +296,7 @@
267
296
  <li class="public ">
268
297
  <span class="summary_signature">
269
298
 
270
- <a href="#handle_closed-instance_method" title="#handle_closed (instance method)">#<strong>handle_closed</strong> &#x21d2; Object </a>
299
+ <a href="#create_cdp_session-instance_method" title="#create_cdp_session (instance method)">#<strong>create_cdp_session</strong> &#x21d2; Object </a>
271
300
 
272
301
 
273
302
 
@@ -373,28 +402,6 @@
373
402
 
374
403
 
375
404
 
376
- <span class="summary_desc"><div class='inline'></div></span>
377
-
378
- </li>
379
-
380
-
381
- <li class="public ">
382
- <span class="summary_signature">
383
-
384
- <a href="#on_close-instance_method" title="#on_close (instance method)">#<strong>on_close</strong>(&amp;block) &#x21d2; Object </a>
385
-
386
-
387
-
388
- </span>
389
-
390
-
391
-
392
-
393
-
394
-
395
-
396
-
397
-
398
405
  <span class="summary_desc"><div class='inline'></div></span>
399
406
 
400
407
  </li>
@@ -638,8 +645,8 @@
638
645
  <span class='ivar'>@initialized_promise</span> <span class='op'>=</span> <span class='ivar'>@initialize_callback_promise</span><span class='period'>.</span><span class='id identifier rubyid_then'>then</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_success'>success</span><span class='op'>|</span>
639
646
  <span class='id identifier rubyid_handle_initialized'>handle_initialized</span><span class='lparen'>(</span><span class='id identifier rubyid_success'>success</span><span class='rparen'>)</span>
640
647
  <span class='kw'>end</span>
641
- <span class='comment'># this._isClosedPromise = new Promise(fulfill =&gt; this._closedCallback = fulfill);
642
- </span>
648
+ <span class='ivar'>@is_closed_promise</span> <span class='op'>=</span> <span class='id identifier rubyid_resolvable_future'><span class='object_link'><a href="ConcurrentRubyUtils.html#resolvable_future-instance_method" title="Puppeteer::ConcurrentRubyUtils#resolvable_future (method)">resolvable_future</a></span></span>
649
+
643
650
  <span class='ivar'>@is_initialized</span> <span class='op'>=</span> <span class='ivar'>@target_info</span><span class='period'>.</span><span class='id identifier rubyid_type'>type</span> <span class='op'>!=</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>page</span><span class='tstring_end'>&#39;</span></span> <span class='op'>||</span> <span class='op'>!</span><span class='ivar'>@target_info</span><span class='period'>.</span><span class='id identifier rubyid_url'>url</span><span class='period'>.</span><span class='id identifier rubyid_empty?'>empty?</span>
644
651
 
645
652
  <span class='kw'>if</span> <span class='ivar'>@is_initialized</span>
@@ -700,6 +707,49 @@
700
707
  </div>
701
708
 
702
709
 
710
+ <span id=""></span>
711
+ <div class="method_details ">
712
+ <h3 class="signature " id="is_closed_promise-instance_method">
713
+
714
+ #<strong>is_closed_promise</strong> &#x21d2; <tt>Object</tt> <span class="extras">(readonly)</span>
715
+
716
+
717
+
718
+
719
+
720
+ </h3><div class="docstring">
721
+ <div class="discussion">
722
+
723
+ <p>Returns the value of attribute is_closed_promise.</p>
724
+
725
+
726
+ </div>
727
+ </div>
728
+ <div class="tags">
729
+
730
+
731
+ </div><table class="source_code">
732
+ <tr>
733
+ <td>
734
+ <pre class="lines">
735
+
736
+
737
+ 49
738
+ 50
739
+ 51</pre>
740
+ </td>
741
+ <td>
742
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 49</span>
743
+
744
+ <span class='kw'>def</span> <span class='id identifier rubyid_is_closed_promise'>is_closed_promise</span>
745
+ <span class='ivar'>@is_closed_promise</span>
746
+ <span class='kw'>end</span></pre>
747
+ </td>
748
+ </tr>
749
+ </table>
750
+ </div>
751
+
752
+
703
753
  <span id=""></span>
704
754
  <div class="method_details ">
705
755
  <h3 class="signature " id="target_id-instance_method">
@@ -786,12 +836,12 @@
786
836
  <pre class="lines">
787
837
 
788
838
 
789
- 128
790
- 129
791
- 130</pre>
839
+ 125
840
+ 126
841
+ 127</pre>
792
842
  </td>
793
843
  <td>
794
- <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 128</span>
844
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 125</span>
795
845
 
796
846
  <span class='kw'>def</span> <span class='id identifier rubyid_browser'>browser</span>
797
847
  <span class='ivar'>@browser_context</span><span class='period'>.</span><span class='id identifier rubyid_browser'>browser</span>
@@ -838,12 +888,12 @@
838
888
  <pre class="lines">
839
889
 
840
890
 
841
- 133
842
- 134
843
- 135</pre>
891
+ 130
892
+ 131
893
+ 132</pre>
844
894
  </td>
845
895
  <td>
846
- <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 133</span>
896
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 130</span>
847
897
 
848
898
  <span class='kw'>def</span> <span class='id identifier rubyid_browser_context'>browser_context</span>
849
899
  <span class='ivar'>@browser_context</span>
@@ -854,9 +904,9 @@
854
904
  </div>
855
905
 
856
906
  <div class="method_details ">
857
- <h3 class="signature " id="create_cdp_session-instance_method">
907
+ <h3 class="signature " id="closed_callback-instance_method">
858
908
 
859
- #<strong>create_cdp_session</strong> &#x21d2; <tt>Object</tt>
909
+ #<strong>closed_callback</strong> &#x21d2; <tt>Object</tt>
860
910
 
861
911
 
862
912
 
@@ -868,15 +918,15 @@
868
918
  <pre class="lines">
869
919
 
870
920
 
871
- 86
872
- 87
873
- 88</pre>
921
+ 51
922
+ 52
923
+ 53</pre>
874
924
  </td>
875
925
  <td>
876
- <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 86</span>
926
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 51</span>
877
927
 
878
- <span class='kw'>def</span> <span class='id identifier rubyid_create_cdp_session'>create_cdp_session</span>
879
- <span class='ivar'>@session_factory</span><span class='period'>.</span><span class='id identifier rubyid_call'>call</span>
928
+ <span class='kw'>def</span> <span class='id identifier rubyid_closed_callback'>closed_callback</span>
929
+ <span class='ivar'>@is_closed_promise</span><span class='period'>.</span><span class='id identifier rubyid_fulfill'>fulfill</span><span class='lparen'>(</span><span class='kw'>true</span><span class='rparen'>)</span>
880
930
  <span class='kw'>end</span></pre>
881
931
  </td>
882
932
  </tr>
@@ -884,9 +934,9 @@
884
934
  </div>
885
935
 
886
936
  <div class="method_details ">
887
- <h3 class="signature " id="handle_closed-instance_method">
937
+ <h3 class="signature " id="create_cdp_session-instance_method">
888
938
 
889
- #<strong>handle_closed</strong> &#x21d2; <tt>Object</tt>
939
+ #<strong>create_cdp_session</strong> &#x21d2; <tt>Object</tt>
890
940
 
891
941
 
892
942
 
@@ -898,17 +948,15 @@
898
948
  <pre class="lines">
899
949
 
900
950
 
901
- 73
902
- 74
903
- 75
904
- 76</pre>
951
+ 83
952
+ 84
953
+ 85</pre>
905
954
  </td>
906
955
  <td>
907
- <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 73</span>
956
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 83</span>
908
957
 
909
- <span class='kw'>def</span> <span class='id identifier rubyid_handle_closed'>handle_closed</span>
910
- <span class='ivar'>@closed</span> <span class='op'>=</span> <span class='kw'>true</span>
911
- <span class='ivar'>@on_close</span><span class='op'>&amp;.</span><span class='id identifier rubyid_call'>call</span>
958
+ <span class='kw'>def</span> <span class='id identifier rubyid_create_cdp_session'>create_cdp_session</span>
959
+ <span class='ivar'>@session_factory</span><span class='period'>.</span><span class='id identifier rubyid_call'>call</span>
912
960
  <span class='kw'>end</span></pre>
913
961
  </td>
914
962
  </tr>
@@ -954,17 +1002,17 @@
954
1002
  <pre class="lines">
955
1003
 
956
1004
 
1005
+ 142
1006
+ 143
1007
+ 144
957
1008
  145
958
1009
  146
959
1010
  147
960
1011
  148
961
- 149
962
- 150
963
- 151
964
- 152</pre>
1012
+ 149</pre>
965
1013
  </td>
966
1014
  <td>
967
- <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 145</span>
1015
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 142</span>
968
1016
 
969
1017
  <span class='kw'>def</span> <span class='id identifier rubyid_handle_target_info_changed'>handle_target_info_changed</span><span class='lparen'>(</span><span class='id identifier rubyid_target_info'>target_info</span><span class='rparen'>)</span>
970
1018
  <span class='ivar'>@target_info</span> <span class='op'>=</span> <span class='id identifier rubyid_target_info'>target_info</span>
@@ -994,15 +1042,19 @@
994
1042
  <pre class="lines">
995
1043
 
996
1044
 
997
- 53
998
- 54
999
- 55</pre>
1045
+ 57
1046
+ 58
1047
+ 59
1048
+ 60
1049
+ 61</pre>
1000
1050
  </td>
1001
1051
  <td>
1002
- <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 53</span>
1052
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 57</span>
1003
1053
 
1004
1054
  <span class='kw'>def</span> <span class='id identifier rubyid_ignore_initialize_callback_promise'>ignore_initialize_callback_promise</span>
1005
- <span class='ivar'>@initialize_callback_promise</span><span class='period'>.</span><span class='id identifier rubyid_fulfill'>fulfill</span><span class='lparen'>(</span><span class='kw'>false</span><span class='rparen'>)</span>
1055
+ <span class='kw'>unless</span> <span class='ivar'>@initialize_callback_promise</span><span class='period'>.</span><span class='id identifier rubyid_fulfilled?'>fulfilled?</span>
1056
+ <span class='ivar'>@initialize_callback_promise</span><span class='period'>.</span><span class='id identifier rubyid_fulfill'>fulfill</span><span class='lparen'>(</span><span class='kw'>false</span><span class='rparen'>)</span>
1057
+ <span class='kw'>end</span>
1006
1058
  <span class='kw'>end</span></pre>
1007
1059
  </td>
1008
1060
  </tr>
@@ -1046,12 +1098,12 @@
1046
1098
  <pre class="lines">
1047
1099
 
1048
1100
 
1049
- 82
1050
- 83
1051
- 84</pre>
1101
+ 79
1102
+ 80
1103
+ 81</pre>
1052
1104
  </td>
1053
1105
  <td>
1054
- <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 82</span>
1106
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 79</span>
1055
1107
 
1056
1108
  <span class='kw'>def</span> <span class='id identifier rubyid_initialized?'>initialized?</span>
1057
1109
  <span class='ivar'>@is_initialized</span>
@@ -1059,36 +1111,6 @@
1059
1111
  </td>
1060
1112
  </tr>
1061
1113
  </table>
1062
- </div>
1063
-
1064
- <div class="method_details ">
1065
- <h3 class="signature " id="on_close-instance_method">
1066
-
1067
- #<strong>on_close</strong>(&amp;block) &#x21d2; <tt>Object</tt>
1068
-
1069
-
1070
-
1071
-
1072
-
1073
- </h3><table class="source_code">
1074
- <tr>
1075
- <td>
1076
- <pre class="lines">
1077
-
1078
-
1079
- 78
1080
- 79
1081
- 80</pre>
1082
- </td>
1083
- <td>
1084
- <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 78</span>
1085
-
1086
- <span class='kw'>def</span> <span class='id identifier rubyid_on_close'>on_close</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1087
- <span class='ivar'>@on_close</span> <span class='op'>=</span> <span class='id identifier rubyid_block'>block</span>
1088
- <span class='kw'>end</span></pre>
1089
- </td>
1090
- </tr>
1091
- </table>
1092
1114
  </div>
1093
1115
 
1094
1116
  <div class="method_details ">
@@ -1128,14 +1150,14 @@
1128
1150
  <pre class="lines">
1129
1151
 
1130
1152
 
1153
+ 135
1154
+ 136
1155
+ 137
1131
1156
  138
1132
- 139
1133
- 140
1134
- 141
1135
- 142</pre>
1157
+ 139</pre>
1136
1158
  </td>
1137
1159
  <td>
1138
- <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 138</span>
1160
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 135</span>
1139
1161
 
1140
1162
  <span class='kw'>def</span> <span class='id identifier rubyid_opener'>opener</span>
1141
1163
  <span class='id identifier rubyid_opener_id'>opener_id</span> <span class='op'>=</span> <span class='ivar'>@target_info</span><span class='period'>.</span><span class='id identifier rubyid_opener_id'>opener_id</span>
@@ -1162,16 +1184,16 @@
1162
1184
  <pre class="lines">
1163
1185
 
1164
1186
 
1187
+ 87
1188
+ 88
1189
+ 89
1165
1190
  90
1166
1191
  91
1167
1192
  92
1168
- 93
1169
- 94
1170
- 95
1171
- 96</pre>
1193
+ 93</pre>
1172
1194
  </td>
1173
1195
  <td>
1174
- <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 90</span>
1196
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 87</span>
1175
1197
 
1176
1198
  <span class='kw'>def</span> <span class='id identifier rubyid_page'>page</span>
1177
1199
  <span class='kw'>if</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>page</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'>background_page</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'>webview</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='period'>.</span><span class='id identifier rubyid_include?'>include?</span><span class='lparen'>(</span><span class='ivar'>@target_info</span><span class='period'>.</span><span class='id identifier rubyid_type'>type</span><span class='rparen'>)</span> <span class='op'>&amp;&amp;</span> <span class='ivar'>@page</span><span class='period'>.</span><span class='id identifier rubyid_nil?'>nil?</span>
@@ -1222,17 +1244,17 @@
1222
1244
  <pre class="lines">
1223
1245
 
1224
1246
 
1247
+ 115
1248
+ 116
1249
+ 117
1225
1250
  118
1226
1251
  119
1227
1252
  120
1228
1253
  121
1229
- 122
1230
- 123
1231
- 124
1232
- 125</pre>
1254
+ 122</pre>
1233
1255
  </td>
1234
1256
  <td>
1235
- <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 118</span>
1257
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 115</span>
1236
1258
 
1237
1259
  <span class='kw'>def</span> <span class='id identifier rubyid_type'>type</span>
1238
1260
  <span class='id identifier rubyid_type'>type</span> <span class='op'>=</span> <span class='ivar'>@target_info</span><span class='period'>.</span><span class='id identifier rubyid_type'>type</span>
@@ -1284,12 +1306,12 @@
1284
1306
  <pre class="lines">
1285
1307
 
1286
1308
 
1287
- 113
1288
- 114
1289
- 115</pre>
1309
+ 110
1310
+ 111
1311
+ 112</pre>
1290
1312
  </td>
1291
1313
  <td>
1292
- <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 113</span>
1314
+ <pre class="code"><span class="info file"># File 'lib/puppeteer/target.rb', line 110</span>
1293
1315
 
1294
1316
  <span class='kw'>def</span> <span class='id identifier rubyid_url'>url</span>
1295
1317
  <span class='ivar'>@target_info</span><span class='period'>.</span><span class='id identifier rubyid_url'>url</span>
@@ -1304,7 +1326,7 @@
1304
1326
  </div>
1305
1327
 
1306
1328
  <div id="footer">
1307
- Generated on Tue Jun 9 00:13:39 2020 by
1329
+ Generated on Fri Jun 12 12:38:33 2020 by
1308
1330
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
1309
1331
  0.9.24 (ruby-2.6.3).
1310
1332
  </div>