Skip to content

Commit b68c729

Browse files
author
Jakub Kulhan
committed
autoupdated protocol.json & generated files
1 parent 5b89308 commit b68c729

File tree

6 files changed

+201
-7
lines changed

6 files changed

+201
-7
lines changed

gen-src/ChromeDevtoolsProtocol/Model/DOMSnapshot/CaptureSnapshotRequest.php

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,13 @@ final class CaptureSnapshotRequest implements \JsonSerializable
1818
*/
1919
public $computedStyles;
2020

21+
/**
22+
* Whether to include DOM rectangles (offsetRects, clientRects, scrollRects) into the snapshot
23+
*
24+
* @var bool|null
25+
*/
26+
public $includeDOMRects;
27+
2128

2229
public static function fromJson($data)
2330
{
@@ -28,6 +35,9 @@ public static function fromJson($data)
2835
$instance->computedStyles[] = (string)$item;
2936
}
3037
}
38+
if (isset($data->includeDOMRects)) {
39+
$instance->includeDOMRects = (bool)$data->includeDOMRects;
40+
}
3141
return $instance;
3242
}
3343

@@ -41,6 +51,9 @@ public function jsonSerialize()
4151
$data->computedStyles[] = $item;
4252
}
4353
}
54+
if ($this->includeDOMRects !== null) {
55+
$data->includeDOMRects = $this->includeDOMRects;
56+
}
4457
return $data;
4558
}
4659

gen-src/ChromeDevtoolsProtocol/Model/DOMSnapshot/CaptureSnapshotRequestBuilder.php

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ final class CaptureSnapshotRequestBuilder
1313
{
1414
private $computedStyles;
1515

16+
private $includeDOMRects;
17+
1618

1719
/**
1820
* Validate non-optional parameters and return new instance.
@@ -24,6 +26,7 @@ public function build(): CaptureSnapshotRequest
2426
throw new BuilderException('Property [computedStyles] is required.');
2527
}
2628
$instance->computedStyles = $this->computedStyles;
29+
$instance->includeDOMRects = $this->includeDOMRects;
2730
return $instance;
2831
}
2932

@@ -38,4 +41,16 @@ public function setComputedStyles($computedStyles): self
3841
$this->computedStyles = $computedStyles;
3942
return $this;
4043
}
44+
45+
46+
/**
47+
* @param bool|null $includeDOMRects
48+
*
49+
* @return self
50+
*/
51+
public function setIncludeDOMRects($includeDOMRects): self
52+
{
53+
$this->includeDOMRects = $includeDOMRects;
54+
return $this;
55+
}
4156
}

gen-src/ChromeDevtoolsProtocol/Model/DOMSnapshot/LayoutTreeSnapshot.php

Lines changed: 99 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,27 @@ final class LayoutTreeSnapshot implements \JsonSerializable
4646
*/
4747
public $stackingContexts;
4848

49+
/**
50+
* The offset rect of nodes. Only available when includeDOMRects is set to true
51+
*
52+
* @var int[][]|float[][]|null
53+
*/
54+
public $offsetRects;
55+
56+
/**
57+
* The scroll rect of nodes. Only available when includeDOMRects is set to true
58+
*
59+
* @var int[][]|float[][]|null
60+
*/
61+
public $scrollRects;
62+
63+
/**
64+
* The client rect of nodes. Only available when includeDOMRects is set to true
65+
*
66+
* @var int[][]|float[][]|null
67+
*/
68+
public $clientRects;
69+
4970

5071
public static function fromJson($data)
5172
{
@@ -94,6 +115,45 @@ public static function fromJson($data)
94115
if (isset($data->stackingContexts)) {
95116
$instance->stackingContexts = RareBooleanData::fromJson($data->stackingContexts);
96117
}
118+
if (isset($data->offsetRects)) {
119+
$instance->offsetRects = [];
120+
if (isset($data->offsetRects)) {
121+
$instance->offsetRects = [];
122+
foreach ($data->offsetRects as $item) {
123+
$nested = [];
124+
foreach ($item as $nestedItem) {
125+
$nested[] = $nestedItem;
126+
}
127+
$instance->offsetRects[] = $nested;
128+
}
129+
}
130+
}
131+
if (isset($data->scrollRects)) {
132+
$instance->scrollRects = [];
133+
if (isset($data->scrollRects)) {
134+
$instance->scrollRects = [];
135+
foreach ($data->scrollRects as $item) {
136+
$nested = [];
137+
foreach ($item as $nestedItem) {
138+
$nested[] = $nestedItem;
139+
}
140+
$instance->scrollRects[] = $nested;
141+
}
142+
}
143+
}
144+
if (isset($data->clientRects)) {
145+
$instance->clientRects = [];
146+
if (isset($data->clientRects)) {
147+
$instance->clientRects = [];
148+
foreach ($data->clientRects as $item) {
149+
$nested = [];
150+
foreach ($item as $nestedItem) {
151+
$nested[] = $nestedItem;
152+
}
153+
$instance->clientRects[] = $nested;
154+
}
155+
}
156+
}
97157
return $instance;
98158
}
99159

@@ -145,6 +205,45 @@ public function jsonSerialize()
145205
if ($this->stackingContexts !== null) {
146206
$data->stackingContexts = $this->stackingContexts->jsonSerialize();
147207
}
208+
if ($this->offsetRects !== null) {
209+
$data->offsetRects = [];
210+
if ($this->offsetRects !== null) {
211+
$data->offsetRects = [];
212+
foreach ($this->offsetRects as $item) {
213+
$nested = [];
214+
foreach ($item as $nestedItem) {
215+
$nested[] = $nestedItem;
216+
}
217+
$data->offsetRects[] = $nested;
218+
}
219+
}
220+
}
221+
if ($this->scrollRects !== null) {
222+
$data->scrollRects = [];
223+
if ($this->scrollRects !== null) {
224+
$data->scrollRects = [];
225+
foreach ($this->scrollRects as $item) {
226+
$nested = [];
227+
foreach ($item as $nestedItem) {
228+
$nested[] = $nestedItem;
229+
}
230+
$data->scrollRects[] = $nested;
231+
}
232+
}
233+
}
234+
if ($this->clientRects !== null) {
235+
$data->clientRects = [];
236+
if ($this->clientRects !== null) {
237+
$data->clientRects = [];
238+
foreach ($this->clientRects as $item) {
239+
$nested = [];
240+
foreach ($item as $nestedItem) {
241+
$nested[] = $nestedItem;
242+
}
243+
$data->clientRects[] = $nested;
244+
}
245+
}
246+
}
148247
return $data;
149248
}
150249
}

gen-src/ChromeDevtoolsProtocol/Model/WebAudio/ContextRealtimeData.php

Lines changed: 29 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
namespace ChromeDevtoolsProtocol\Model\WebAudio;
44

55
/**
6-
* Fields in AudioContext that change in real-time. These are not updated on OfflineAudioContext.
6+
* Fields in AudioContext that change in real-time.
77
*
88
* @generated This file has been auto-generated, do not edit.
99
*
@@ -14,17 +14,31 @@ final class ContextRealtimeData implements \JsonSerializable
1414
/**
1515
* The current context time in second in BaseAudioContext.
1616
*
17-
* @var int|float|null
17+
* @var int|float
1818
*/
1919
public $currentTime;
2020

2121
/**
2222
* The time spent on rendering graph divided by render qunatum duration, and multiplied by 100. 100 means the audio renderer reached the full capacity and glitch may occur.
2323
*
24-
* @var int|float|null
24+
* @var int|float
2525
*/
2626
public $renderCapacity;
2727

28+
/**
29+
* A running mean of callback interval.
30+
*
31+
* @var int|float
32+
*/
33+
public $callbackIntervalMean;
34+
35+
/**
36+
* A running variance of callback interval.
37+
*
38+
* @var int|float
39+
*/
40+
public $callbackIntervalVariance;
41+
2842

2943
public static function fromJson($data)
3044
{
@@ -35,6 +49,12 @@ public static function fromJson($data)
3549
if (isset($data->renderCapacity)) {
3650
$instance->renderCapacity = $data->renderCapacity;
3751
}
52+
if (isset($data->callbackIntervalMean)) {
53+
$instance->callbackIntervalMean = $data->callbackIntervalMean;
54+
}
55+
if (isset($data->callbackIntervalVariance)) {
56+
$instance->callbackIntervalVariance = $data->callbackIntervalVariance;
57+
}
3858
return $instance;
3959
}
4060

@@ -48,6 +68,12 @@ public function jsonSerialize()
4868
if ($this->renderCapacity !== null) {
4969
$data->renderCapacity = $this->renderCapacity;
5070
}
71+
if ($this->callbackIntervalMean !== null) {
72+
$data->callbackIntervalMean = $this->callbackIntervalMean;
73+
}
74+
if ($this->callbackIntervalVariance !== null) {
75+
$data->callbackIntervalVariance = $this->callbackIntervalVariance;
76+
}
5177
return $data;
5278
}
5379
}

protocol.json

Lines changed: 44 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6675,6 +6675,33 @@
66756675
"name": "stackingContexts",
66766676
"description": "Stacking context information.",
66776677
"$ref": "RareBooleanData"
6678+
},
6679+
{
6680+
"name": "offsetRects",
6681+
"description": "The offset rect of nodes. Only available when includeDOMRects is set to true",
6682+
"optional": true,
6683+
"type": "array",
6684+
"items": {
6685+
"$ref": "Rectangle"
6686+
}
6687+
},
6688+
{
6689+
"name": "scrollRects",
6690+
"description": "The scroll rect of nodes. Only available when includeDOMRects is set to true",
6691+
"optional": true,
6692+
"type": "array",
6693+
"items": {
6694+
"$ref": "Rectangle"
6695+
}
6696+
},
6697+
{
6698+
"name": "clientRects",
6699+
"description": "The client rect of nodes. Only available when includeDOMRects is set to true",
6700+
"optional": true,
6701+
"type": "array",
6702+
"items": {
6703+
"$ref": "Rectangle"
6704+
}
66786705
}
66796706
]
66806707
},
@@ -6730,6 +6757,12 @@
67306757
"items": {
67316758
"type": "string"
67326759
}
6760+
},
6761+
{
6762+
"name": "includeDOMRects",
6763+
"description": "Whether to include DOM rectangles (offsetRects, clientRects, scrollRects) into the snapshot",
6764+
"optional": true,
6765+
"type": "boolean"
67336766
}
67346767
],
67356768
"returns": [
@@ -17901,19 +17934,27 @@
1790117934
},
1790217935
{
1790317936
"id": "ContextRealtimeData",
17904-
"description": "Fields in AudioContext that change in real-time. These are not updated on OfflineAudioContext.",
17937+
"description": "Fields in AudioContext that change in real-time.",
1790517938
"type": "object",
1790617939
"properties": [
1790717940
{
1790817941
"name": "currentTime",
1790917942
"description": "The current context time in second in BaseAudioContext.",
17910-
"optional": true,
1791117943
"type": "number"
1791217944
},
1791317945
{
1791417946
"name": "renderCapacity",
1791517947
"description": "The time spent on rendering graph divided by render qunatum duration, and multiplied by 100. 100 means the audio renderer reached the full capacity and glitch may occur.",
17916-
"optional": true,
17948+
"type": "number"
17949+
},
17950+
{
17951+
"name": "callbackIntervalMean",
17952+
"description": "A running mean of callback interval.",
17953+
"type": "number"
17954+
},
17955+
{
17956+
"name": "callbackIntervalVariance",
17957+
"description": "A running variance of callback interval.",
1791717958
"type": "number"
1791817959
}
1791917960
]

protocol.json.md5

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
1700dccae17ee1c60fe4b9e2c320a20a protocol.json
1+
47fdaabbe7bba88c3949e2d1ba4a642d protocol.json

0 commit comments

Comments
 (0)