001package Torello.Browser.BrowserAPI; 002 003// *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** 004// Java-HTML Imports 005// *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** 006 007import Torello.Browser.*; 008import Torello.Browser.helper.*; 009import Torello.Browser.JavaScriptAPI.*; 010import Torello.JSON.*; 011 012import Torello.Java.ReadOnly.ReadOnlyList; 013import Torello.Java.ReadOnly.ReadOnlyArrayList; 014 015import Torello.JavaDoc.Annotations.StaticFunctional; 016import Torello.JavaDoc.Annotations.JDHeaderBackgroundImg; 017 018import Torello.Browser.BrowserAPI.NestedHelpers.Commands.CSS$$Commands; 019 020 021// *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** 022// JDK Imports 023// *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** 024 025import javax.json.JsonObject; 026import javax.json.JsonValue; 027 028/** 029 * <SPAN CLASS=COPIEDJDK><B>This domain exposes CSS read/write operations. All CSS objects (stylesheets, rules, and styles) 030 * have an associated <CODE>id</CODE> used in subsequent operations on the related object. Each object type has 031 * a specific <CODE>id</CODE> structure, and those are not interchangeable between objects of different kinds. 032 * CSS objects can be loaded using the <CODE>get*ForNode()</CODE> calls (which accept a DOM node id). A client 033 * can also keep track of stylesheets via the <CODE>styleSheetAdded</CODE>/<CODE>styleSheetRemoved</CODE> events and 034 * subsequently load the required stylesheet contents using the <CODE>getStyleSheet[Text]()</CODE> methods.</B></SPAN> 035 * <EMBED CLASS='external-html' DATA-FILE-ID=CDP.CODE_GEN_NOTE> 036 */ 037@StaticFunctional@JDHeaderBackgroundImg(EmbedTagFileID="CDP.WOOD_PLANK_NOTE") 038public class CSS 039{ 040 // No Pubic Constructors 041 private CSS() { } 042 043 044 // ******************************************************************************************** 045 // ******************************************************************************************** 046 // Eliminated Types 047 // ******************************************************************************************** 048 // ******************************************************************************************** 049 050 051 /** 052 * <CODE>[No Description Provided by Google]</CODE> 053 054 * <EMBED CLASS='external-html' DATA-CTAS='String' DATA-FILE-ID=CDP.EliminatedType 055 * DATA-NAME=StyleSheetId> 056 */ 057 public static final String StyleSheetId = 058 "StyleSheetId has been eliminated.\n" + 059 "It was replaced with the standard Java-Type: String"; 060 061 062 // ******************************************************************************************** 063 // ******************************************************************************************** 064 // Marker Events 065 // ******************************************************************************************** 066 // ******************************************************************************************** 067 068 069 /** 070 * Fires whenever a MediaQuery result changes (for example, after a browser window has been 071 * resized.) The current implementation considers only viewport-dependent media features. 072 073 * 074 * <EMBED CLASS='external-html' DATA-FILE-ID=CDP.MarkerEvent 075 * DATA-NAME=mediaQueryResultChanged> 076 */ 077 public static final String mediaQueryResultChanged = "CSS.mediaQueryResultChanged Marker Event"; 078 079 080 // ******************************************************************************************** 081 // ******************************************************************************************** 082 // Enumerated String Constants Lists 083 // ******************************************************************************************** 084 // ******************************************************************************************** 085 086 087 /** 088 * Enum indicating the type of a CSS rule, used to represent the order of a style rule's ancestors. 089 * This list only contains rule types that are collected during the ancestor rule collection. 090 * 091 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 092 * <BR /><BR /><B CLASS=StrEnumType>String-Enumeration Type</B> 093 */ 094 public static final ReadOnlyList<String> CSSRuleType = new ReadOnlyArrayList<>( 095 String.class, 096 "ContainerRule", "LayerRule", "MediaRule", "ScopeRule", "StartingStyleRule", "StyleRule", 097 "SupportsRule" 098 ); 099 100 /** 101 * Stylesheet type: "injected" for stylesheets injected via extension, "user-agent" for user-agent 102 * stylesheets, "inspector" for stylesheets created by the inspector (i.e. those holding the "via 103 * inspector" rules), "regular" for regular stylesheets. 104 * <BR /><BR /><B CLASS=StrEnumType>String-Enumeration Type</B> 105 */ 106 public static final ReadOnlyList<String> StyleSheetOrigin = new ReadOnlyArrayList<> 107 (String.class, "injected", "inspector", "regular", "user-agent"); 108 109 110 111 // ******************************************************************************************** 112 // ******************************************************************************************** 113 // Basic Types 114 // ******************************************************************************************** 115 // ******************************************************************************************** 116 117 118 /** 119 * CSS style coming from animations with the name of the animation. 120 * 121 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 122 */ 123 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 124 public static class CSSAnimationStyle 125 extends BaseType<CSSAnimationStyle> 126 implements java.io.Serializable 127 { 128 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 129 protected static final long serialVersionUID = 1; 130 131 private static final NestedHelper<CSS.CSSAnimationStyle> singleton = 132 Torello.Browser.BrowserAPI.NestedHelpers.Types. 133 CSS$$CSSAnimationStyle$$.singleton; 134 135 /** 136 * The name of the animation. 137 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 138 */ 139 public final String name; 140 141 /** The style coming from the animation. */ 142 public final CSS.CSSStyle style; 143 144 /** Constructor. Please review this class' fields for documentation. */ 145 public CSSAnimationStyle(ReadOnlyList<Boolean> isPresent, String name, CSSStyle style) 146 { 147 super(singleton, Domains.CSS, "CSSAnimationStyle", 2); 148 149 this.name = name; 150 this.style = style; 151 152 this.isPresent = (isPresent == null) 153 ? singleton.generateIsPresentList(this) 154 : THROWS.check(isPresent, 2, "CSS.CSSAnimationStyle"); 155 } 156 157 /** Creates an instance of this class from a {@link JsonObject}.*/ 158 public static CSSAnimationStyle fromJSON(JsonObject jo) 159 { return singleton.fromJSON(jo); } 160 161 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 162 public static NestedDescriptor<CSSAnimationStyle> descriptor() 163 { return singleton.descriptor(); } 164 } 165 166 /** 167 * <CODE>[No Description Provided by Google]</CODE> 168 * 169 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 170 */ 171 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 172 public static class CSSComputedStyleProperty 173 extends BaseType<CSSComputedStyleProperty> 174 implements java.io.Serializable 175 { 176 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 177 protected static final long serialVersionUID = 1; 178 179 private static final NestedHelper<CSS.CSSComputedStyleProperty> singleton = 180 Torello.Browser.BrowserAPI.NestedHelpers.Types. 181 CSS$$CSSComputedStyleProperty$$.singleton; 182 183 /** Computed style property name. */ 184 public final String name; 185 186 /** Computed style property value. */ 187 public final String value; 188 189 /** Constructor. Please review this class' fields for documentation. */ 190 public CSSComputedStyleProperty(ReadOnlyList<Boolean> isPresent, String name, String value) 191 { 192 super(singleton, Domains.CSS, "CSSComputedStyleProperty", 2); 193 194 this.name = name; 195 this.value = value; 196 197 this.isPresent = (isPresent == null) 198 ? singleton.generateIsPresentList(this) 199 : THROWS.check(isPresent, 2, "CSS.CSSComputedStyleProperty"); 200 } 201 202 /** Creates an instance of this class from a {@link JsonObject}.*/ 203 public static CSSComputedStyleProperty fromJSON(JsonObject jo) 204 { return singleton.fromJSON(jo); } 205 206 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 207 public static NestedDescriptor<CSSComputedStyleProperty> descriptor() 208 { return singleton.descriptor(); } 209 } 210 211 /** 212 * CSS container query rule descriptor. 213 * 214 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 215 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 216 */ 217 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 218 public static class CSSContainerQuery 219 extends BaseType<CSSContainerQuery> 220 implements java.io.Serializable 221 { 222 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 223 protected static final long serialVersionUID = 1; 224 225 private static final NestedHelper<CSS.CSSContainerQuery> singleton = 226 Torello.Browser.BrowserAPI.NestedHelpers.Types. 227 CSS$$CSSContainerQuery$$.singleton; 228 229 /** Container query text. */ 230 public final String text; 231 232 /** 233 * The associated rule header range in the enclosing stylesheet (if 234 * available). 235 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 236 */ 237 public final CSS.SourceRange range; 238 239 /** 240 * Identifier of the stylesheet containing this object (if exists). 241 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 242 */ 243 public final String styleSheetId; 244 245 /** 246 * Optional name for the container. 247 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 248 */ 249 public final String name; 250 251 /** 252 * Optional physical axes queried for the container. 253 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 254 * <EMBED CLASS='external-html' DATA-D=DOM DATA-C=PhysicalAxes DATA-F=physicalAxes DATA-FILE-ID=CDP.EL2> 255 * @see BaseType#enumStrList(String) 256 */ 257 public final String physicalAxes; 258 259 /** 260 * Optional logical axes queried for the container. 261 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 262 * <EMBED CLASS='external-html' DATA-D=DOM DATA-C=LogicalAxes DATA-F=logicalAxes DATA-FILE-ID=CDP.EL2> 263 * @see BaseType#enumStrList(String) 264 */ 265 public final String logicalAxes; 266 267 /** 268 * true if the query contains scroll-state() queries. 269 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 270 */ 271 public final Boolean queriesScrollState; 272 273 /** 274 * true if the query contains anchored() queries. 275 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 276 */ 277 public final Boolean queriesAnchored; 278 279 /** Constructor. Please review this class' fields for documentation. */ 280 public CSSContainerQuery( 281 ReadOnlyList<Boolean> isPresent, String text, SourceRange range, 282 String styleSheetId, String name, String physicalAxes, String logicalAxes, 283 Boolean queriesScrollState, Boolean queriesAnchored 284 ) 285 { 286 super(singleton, Domains.CSS, "CSSContainerQuery", 8); 287 288 this.text = text; 289 this.range = range; 290 this.styleSheetId = styleSheetId; 291 this.name = name; 292 this.physicalAxes = physicalAxes; 293 this.logicalAxes = logicalAxes; 294 this.queriesScrollState = queriesScrollState; 295 this.queriesAnchored = queriesAnchored; 296 297 this.isPresent = (isPresent == null) 298 ? singleton.generateIsPresentList(this) 299 : THROWS.check(isPresent, 8, "CSS.CSSContainerQuery"); 300 } 301 302 /** Creates an instance of this class from a {@link JsonObject}.*/ 303 public static CSSContainerQuery fromJSON(JsonObject jo) 304 { return singleton.fromJSON(jo); } 305 306 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 307 public static NestedDescriptor<CSSContainerQuery> descriptor() 308 { return singleton.descriptor(); } 309 } 310 311 /** 312 * CSS font-palette-values rule representation. 313 * 314 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 315 */ 316 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 317 public static class CSSFontPaletteValuesRule 318 extends BaseType<CSSFontPaletteValuesRule> 319 implements java.io.Serializable 320 { 321 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 322 protected static final long serialVersionUID = 1; 323 324 private static final NestedHelper<CSS.CSSFontPaletteValuesRule> singleton = 325 Torello.Browser.BrowserAPI.NestedHelpers.Types. 326 CSS$$CSSFontPaletteValuesRule$$.singleton; 327 328 /** 329 * The css style sheet identifier (absent for user agent stylesheet and user-specified 330 * stylesheet rules) this rule came from. 331 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 332 */ 333 public final String styleSheetId; 334 335 /** 336 * Parent stylesheet's origin. 337 * <EMBED CLASS='external-html' DATA-D=CSS DATA-C=StyleSheetOrigin DATA-F=origin DATA-FILE-ID=CDP.EL2> 338 * @see BaseType#enumStrList(String) 339 */ 340 public final String origin; 341 342 /** Associated font palette name. */ 343 public final CSS.Value fontPaletteName; 344 345 /** Associated style declaration. */ 346 public final CSS.CSSStyle style; 347 348 /** Constructor. Please review this class' fields for documentation. */ 349 public CSSFontPaletteValuesRule( 350 ReadOnlyList<Boolean> isPresent, String styleSheetId, String origin, 351 Value fontPaletteName, CSSStyle style 352 ) 353 { 354 super(singleton, Domains.CSS, "CSSFontPaletteValuesRule", 4); 355 356 this.styleSheetId = styleSheetId; 357 this.origin = origin; 358 this.fontPaletteName = fontPaletteName; 359 this.style = style; 360 361 this.isPresent = (isPresent == null) 362 ? singleton.generateIsPresentList(this) 363 : THROWS.check(isPresent, 4, "CSS.CSSFontPaletteValuesRule"); 364 } 365 366 /** Creates an instance of this class from a {@link JsonObject}.*/ 367 public static CSSFontPaletteValuesRule fromJSON(JsonObject jo) 368 { return singleton.fromJSON(jo); } 369 370 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 371 public static NestedDescriptor<CSSFontPaletteValuesRule> descriptor() 372 { return singleton.descriptor(); } 373 } 374 375 /** 376 * CSS function conditional block representation. 377 * 378 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 379 */ 380 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 381 public static class CSSFunctionConditionNode 382 extends BaseType<CSSFunctionConditionNode> 383 implements java.io.Serializable 384 { 385 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 386 protected static final long serialVersionUID = 1; 387 388 private static final NestedHelper<CSS.CSSFunctionConditionNode> singleton = 389 Torello.Browser.BrowserAPI.NestedHelpers.Types. 390 CSS$$CSSFunctionConditionNode$$.singleton; 391 392 /** 393 * Media query for this conditional block. Only one type of condition should be set. 394 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 395 */ 396 public final CSS.CSSMedia media; 397 398 /** 399 * Container query for this conditional block. Only one type of condition should be set. 400 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 401 */ 402 public final CSS.CSSContainerQuery containerQueries; 403 404 /** 405 * @supports CSS at-rule condition. Only one type of condition should be set. 406 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 407 */ 408 public final CSS.CSSSupports supports; 409 410 /** Block body. */ 411 public final CSS.CSSFunctionNode[] children; 412 413 /** The condition text. */ 414 public final String conditionText; 415 416 /** Constructor. Please review this class' fields for documentation. */ 417 public CSSFunctionConditionNode( 418 ReadOnlyList<Boolean> isPresent, CSSMedia media, 419 CSSContainerQuery containerQueries, CSSSupports supports, 420 CSSFunctionNode[] children, String conditionText 421 ) 422 { 423 super(singleton, Domains.CSS, "CSSFunctionConditionNode", 5); 424 425 this.media = media; 426 this.containerQueries = containerQueries; 427 this.supports = supports; 428 this.children = children; 429 this.conditionText = conditionText; 430 431 this.isPresent = (isPresent == null) 432 ? singleton.generateIsPresentList(this) 433 : THROWS.check(isPresent, 5, "CSS.CSSFunctionConditionNode"); 434 } 435 436 /** Creates an instance of this class from a {@link JsonObject}.*/ 437 public static CSSFunctionConditionNode fromJSON(JsonObject jo) 438 { return singleton.fromJSON(jo); } 439 440 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 441 public static NestedDescriptor<CSSFunctionConditionNode> descriptor() 442 { return singleton.descriptor(); } 443 } 444 445 /** 446 * Section of the body of a CSS function rule. 447 * 448 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 449 */ 450 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 451 public static class CSSFunctionNode 452 extends BaseType<CSSFunctionNode> 453 implements java.io.Serializable 454 { 455 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 456 protected static final long serialVersionUID = 1; 457 458 private static final NestedHelper<CSS.CSSFunctionNode> singleton = 459 Torello.Browser.BrowserAPI.NestedHelpers.Types. 460 CSS$$CSSFunctionNode$$.singleton; 461 462 /** 463 * A conditional block. If set, style should not be set. 464 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 465 */ 466 public final CSS.CSSFunctionConditionNode condition; 467 468 /** 469 * Values set by this node. If set, condition should not be set. 470 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 471 */ 472 public final CSS.CSSStyle style; 473 474 /** Constructor. Please review this class' fields for documentation. */ 475 public CSSFunctionNode 476 (ReadOnlyList<Boolean> isPresent, CSSFunctionConditionNode condition, CSSStyle style) 477 { 478 super(singleton, Domains.CSS, "CSSFunctionNode", 2); 479 480 this.condition = condition; 481 this.style = style; 482 483 this.isPresent = (isPresent == null) 484 ? singleton.generateIsPresentList(this) 485 : THROWS.check(isPresent, 2, "CSS.CSSFunctionNode"); 486 } 487 488 /** Creates an instance of this class from a {@link JsonObject}.*/ 489 public static CSSFunctionNode fromJSON(JsonObject jo) 490 { return singleton.fromJSON(jo); } 491 492 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 493 public static NestedDescriptor<CSSFunctionNode> descriptor() 494 { return singleton.descriptor(); } 495 } 496 497 /** 498 * CSS function argument representation. 499 * 500 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 501 */ 502 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 503 public static class CSSFunctionParameter 504 extends BaseType<CSSFunctionParameter> 505 implements java.io.Serializable 506 { 507 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 508 protected static final long serialVersionUID = 1; 509 510 private static final NestedHelper<CSS.CSSFunctionParameter> singleton = 511 Torello.Browser.BrowserAPI.NestedHelpers.Types. 512 CSS$$CSSFunctionParameter$$.singleton; 513 514 /** The parameter name. */ 515 public final String name; 516 517 /** The parameter type. */ 518 public final String type; 519 520 /** Constructor. Please review this class' fields for documentation. */ 521 public CSSFunctionParameter(ReadOnlyList<Boolean> isPresent, String name, String type) 522 { 523 super(singleton, Domains.CSS, "CSSFunctionParameter", 2); 524 525 this.name = name; 526 this.type = type; 527 528 this.isPresent = (isPresent == null) 529 ? singleton.generateIsPresentList(this) 530 : THROWS.check(isPresent, 2, "CSS.CSSFunctionParameter"); 531 } 532 533 /** Creates an instance of this class from a {@link JsonObject}.*/ 534 public static CSSFunctionParameter fromJSON(JsonObject jo) 535 { return singleton.fromJSON(jo); } 536 537 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 538 public static NestedDescriptor<CSSFunctionParameter> descriptor() 539 { return singleton.descriptor(); } 540 } 541 542 /** 543 * CSS function at-rule representation. 544 * 545 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 546 */ 547 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 548 public static class CSSFunctionRule 549 extends BaseType<CSSFunctionRule> 550 implements java.io.Serializable 551 { 552 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 553 protected static final long serialVersionUID = 1; 554 555 private static final NestedHelper<CSS.CSSFunctionRule> singleton = 556 Torello.Browser.BrowserAPI.NestedHelpers.Types. 557 CSS$$CSSFunctionRule$$.singleton; 558 559 /** Name of the function. */ 560 public final CSS.Value name; 561 562 /** 563 * The css style sheet identifier (absent for user agent stylesheet and user-specified 564 * stylesheet rules) this rule came from. 565 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 566 */ 567 public final String styleSheetId; 568 569 /** 570 * Parent stylesheet's origin. 571 * <EMBED CLASS='external-html' DATA-D=CSS DATA-C=StyleSheetOrigin DATA-F=origin DATA-FILE-ID=CDP.EL2> 572 * @see BaseType#enumStrList(String) 573 */ 574 public final String origin; 575 576 /** List of parameters. */ 577 public final CSS.CSSFunctionParameter[] parameters; 578 579 /** Function body. */ 580 public final CSS.CSSFunctionNode[] children; 581 582 /** Constructor. Please review this class' fields for documentation. */ 583 public CSSFunctionRule( 584 ReadOnlyList<Boolean> isPresent, Value name, String styleSheetId, String origin, 585 CSSFunctionParameter[] parameters, CSSFunctionNode[] children 586 ) 587 { 588 super(singleton, Domains.CSS, "CSSFunctionRule", 5); 589 590 this.name = name; 591 this.styleSheetId = styleSheetId; 592 this.origin = origin; 593 this.parameters = parameters; 594 this.children = children; 595 596 this.isPresent = (isPresent == null) 597 ? singleton.generateIsPresentList(this) 598 : THROWS.check(isPresent, 5, "CSS.CSSFunctionRule"); 599 } 600 601 /** Creates an instance of this class from a {@link JsonObject}.*/ 602 public static CSSFunctionRule fromJSON(JsonObject jo) 603 { return singleton.fromJSON(jo); } 604 605 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 606 public static NestedDescriptor<CSSFunctionRule> descriptor() 607 { return singleton.descriptor(); } 608 } 609 610 /** 611 * CSS keyframe rule representation. 612 * 613 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 614 */ 615 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 616 public static class CSSKeyframeRule 617 extends BaseType<CSSKeyframeRule> 618 implements java.io.Serializable 619 { 620 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 621 protected static final long serialVersionUID = 1; 622 623 private static final NestedHelper<CSS.CSSKeyframeRule> singleton = 624 Torello.Browser.BrowserAPI.NestedHelpers.Types. 625 CSS$$CSSKeyframeRule$$.singleton; 626 627 /** 628 * The css style sheet identifier (absent for user agent stylesheet and user-specified 629 * stylesheet rules) this rule came from. 630 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 631 */ 632 public final String styleSheetId; 633 634 /** 635 * Parent stylesheet's origin. 636 * <EMBED CLASS='external-html' DATA-D=CSS DATA-C=StyleSheetOrigin DATA-F=origin DATA-FILE-ID=CDP.EL2> 637 * @see BaseType#enumStrList(String) 638 */ 639 public final String origin; 640 641 /** Associated key text. */ 642 public final CSS.Value keyText; 643 644 /** Associated style declaration. */ 645 public final CSS.CSSStyle style; 646 647 /** Constructor. Please review this class' fields for documentation. */ 648 public CSSKeyframeRule( 649 ReadOnlyList<Boolean> isPresent, String styleSheetId, String origin, Value keyText, 650 CSSStyle style 651 ) 652 { 653 super(singleton, Domains.CSS, "CSSKeyframeRule", 4); 654 655 this.styleSheetId = styleSheetId; 656 this.origin = origin; 657 this.keyText = keyText; 658 this.style = style; 659 660 this.isPresent = (isPresent == null) 661 ? singleton.generateIsPresentList(this) 662 : THROWS.check(isPresent, 4, "CSS.CSSKeyframeRule"); 663 } 664 665 /** Creates an instance of this class from a {@link JsonObject}.*/ 666 public static CSSKeyframeRule fromJSON(JsonObject jo) 667 { return singleton.fromJSON(jo); } 668 669 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 670 public static NestedDescriptor<CSSKeyframeRule> descriptor() 671 { return singleton.descriptor(); } 672 } 673 674 /** 675 * CSS keyframes rule representation. 676 * 677 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 678 */ 679 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 680 public static class CSSKeyframesRule 681 extends BaseType<CSSKeyframesRule> 682 implements java.io.Serializable 683 { 684 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 685 protected static final long serialVersionUID = 1; 686 687 private static final NestedHelper<CSS.CSSKeyframesRule> singleton = 688 Torello.Browser.BrowserAPI.NestedHelpers.Types. 689 CSS$$CSSKeyframesRule$$.singleton; 690 691 /** Animation name. */ 692 public final CSS.Value animationName; 693 694 /** List of keyframes. */ 695 public final CSS.CSSKeyframeRule[] keyframes; 696 697 /** Constructor. Please review this class' fields for documentation. */ 698 public CSSKeyframesRule 699 (ReadOnlyList<Boolean> isPresent, Value animationName, CSSKeyframeRule[] keyframes) 700 { 701 super(singleton, Domains.CSS, "CSSKeyframesRule", 2); 702 703 this.animationName = animationName; 704 this.keyframes = keyframes; 705 706 this.isPresent = (isPresent == null) 707 ? singleton.generateIsPresentList(this) 708 : THROWS.check(isPresent, 2, "CSS.CSSKeyframesRule"); 709 } 710 711 /** Creates an instance of this class from a {@link JsonObject}.*/ 712 public static CSSKeyframesRule fromJSON(JsonObject jo) 713 { return singleton.fromJSON(jo); } 714 715 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 716 public static NestedDescriptor<CSSKeyframesRule> descriptor() 717 { return singleton.descriptor(); } 718 } 719 720 /** 721 * CSS Layer at-rule descriptor. 722 * 723 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 724 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 725 */ 726 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 727 public static class CSSLayer 728 extends BaseType<CSSLayer> 729 implements java.io.Serializable 730 { 731 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 732 protected static final long serialVersionUID = 1; 733 734 private static final NestedHelper<CSS.CSSLayer> singleton = 735 Torello.Browser.BrowserAPI.NestedHelpers.Types. 736 CSS$$CSSLayer$$.singleton; 737 738 /** Layer name. */ 739 public final String text; 740 741 /** 742 * The associated rule header range in the enclosing stylesheet (if 743 * available). 744 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 745 */ 746 public final CSS.SourceRange range; 747 748 /** 749 * Identifier of the stylesheet containing this object (if exists). 750 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 751 */ 752 public final String styleSheetId; 753 754 /** Constructor. Please review this class' fields for documentation. */ 755 public CSSLayer 756 (ReadOnlyList<Boolean> isPresent, String text, SourceRange range, String styleSheetId) 757 { 758 super(singleton, Domains.CSS, "CSSLayer", 3); 759 760 this.text = text; 761 this.range = range; 762 this.styleSheetId = styleSheetId; 763 764 this.isPresent = (isPresent == null) 765 ? singleton.generateIsPresentList(this) 766 : THROWS.check(isPresent, 3, "CSS.CSSLayer"); 767 } 768 769 /** Creates an instance of this class from a {@link JsonObject}.*/ 770 public static CSSLayer fromJSON(JsonObject jo) 771 { return singleton.fromJSON(jo); } 772 773 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 774 public static NestedDescriptor<CSSLayer> descriptor() 775 { return singleton.descriptor(); } 776 } 777 778 /** 779 * CSS Layer data. 780 * 781 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 782 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 783 */ 784 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 785 public static class CSSLayerData 786 extends BaseType<CSSLayerData> 787 implements java.io.Serializable 788 { 789 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 790 protected static final long serialVersionUID = 1; 791 792 private static final NestedHelper<CSS.CSSLayerData> singleton = 793 Torello.Browser.BrowserAPI.NestedHelpers.Types. 794 CSS$$CSSLayerData$$.singleton; 795 796 /** Layer name. */ 797 public final String name; 798 799 /** 800 * Direct sub-layers 801 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 802 */ 803 public final CSS.CSSLayerData[] subLayers; 804 805 /** 806 * Layer order. The order determines the order of the layer in the cascade order. 807 * A higher number has higher priority in the cascade order. 808 */ 809 public final Number order; 810 811 /** Constructor. Please review this class' fields for documentation. */ 812 public CSSLayerData 813 (ReadOnlyList<Boolean> isPresent, String name, CSSLayerData[] subLayers, Number order) 814 { 815 super(singleton, Domains.CSS, "CSSLayerData", 3); 816 817 this.name = name; 818 this.subLayers = subLayers; 819 this.order = order; 820 821 this.isPresent = (isPresent == null) 822 ? singleton.generateIsPresentList(this) 823 : THROWS.check(isPresent, 3, "CSS.CSSLayerData"); 824 } 825 826 /** Creates an instance of this class from a {@link JsonObject}.*/ 827 public static CSSLayerData fromJSON(JsonObject jo) 828 { return singleton.fromJSON(jo); } 829 830 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 831 public static NestedDescriptor<CSSLayerData> descriptor() 832 { return singleton.descriptor(); } 833 } 834 835 /** 836 * CSS media rule descriptor. 837 * 838 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 839 */ 840 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 841 public static class CSSMedia 842 extends BaseType<CSSMedia> 843 implements java.io.Serializable 844 { 845 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 846 protected static final long serialVersionUID = 1; 847 848 private static final NestedHelper<CSS.CSSMedia> singleton = 849 Torello.Browser.BrowserAPI.NestedHelpers.Types. 850 CSS$$CSSMedia$$.singleton; 851 852 /** Media query text. */ 853 public final String text; 854 855 /** 856 * Source of the media query: "mediaRule" if specified by a @media rule, "importRule" if 857 * specified by an @import rule, "linkedSheet" if specified by a "media" attribute in a linked 858 * stylesheet's LINK tag, "inlineSheet" if specified by a "media" attribute in an inline 859 * stylesheet's STYLE tag. 860 * <EMBED CLASS='external-html' DATA-D=CSS DATA-C=CSSMedia DATA-F=source DATA-FILE-ID=CDP.EL1> 861 * @see BaseType#enumStrList(String) 862 */ 863 public final String source; 864 865 /** 866 * URL of the document containing the media query description. 867 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 868 */ 869 public final String sourceURL; 870 871 /** 872 * The associated rule (@media or @import) header range in the enclosing stylesheet (if 873 * available). 874 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 875 */ 876 public final CSS.SourceRange range; 877 878 /** 879 * Identifier of the stylesheet containing this object (if exists). 880 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 881 */ 882 public final String styleSheetId; 883 884 /** 885 * Array of media queries. 886 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 887 */ 888 public final CSS.MediaQuery[] mediaList; 889 890 /** Constructor. Please review this class' fields for documentation. */ 891 public CSSMedia( 892 ReadOnlyList<Boolean> isPresent, String text, String source, String sourceURL, 893 SourceRange range, String styleSheetId, MediaQuery[] mediaList 894 ) 895 { 896 super(singleton, Domains.CSS, "CSSMedia", 6); 897 898 this.text = text; 899 this.source = source; 900 this.sourceURL = sourceURL; 901 this.range = range; 902 this.styleSheetId = styleSheetId; 903 this.mediaList = mediaList; 904 905 this.isPresent = (isPresent == null) 906 ? singleton.generateIsPresentList(this) 907 : THROWS.check(isPresent, 6, "CSS.CSSMedia"); 908 } 909 910 /** Creates an instance of this class from a {@link JsonObject}.*/ 911 public static CSSMedia fromJSON(JsonObject jo) 912 { return singleton.fromJSON(jo); } 913 914 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 915 public static NestedDescriptor<CSSMedia> descriptor() 916 { return singleton.descriptor(); } 917 } 918 919 /** 920 * CSS @position-try rule representation. 921 * 922 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 923 */ 924 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 925 public static class CSSPositionTryRule 926 extends BaseType<CSSPositionTryRule> 927 implements java.io.Serializable 928 { 929 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 930 protected static final long serialVersionUID = 1; 931 932 private static final NestedHelper<CSS.CSSPositionTryRule> singleton = 933 Torello.Browser.BrowserAPI.NestedHelpers.Types. 934 CSS$$CSSPositionTryRule$$.singleton; 935 936 /** The prelude dashed-ident name */ 937 public final CSS.Value name; 938 939 /** 940 * The css style sheet identifier (absent for user agent stylesheet and user-specified 941 * stylesheet rules) this rule came from. 942 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 943 */ 944 public final String styleSheetId; 945 946 /** 947 * Parent stylesheet's origin. 948 * <EMBED CLASS='external-html' DATA-D=CSS DATA-C=StyleSheetOrigin DATA-F=origin DATA-FILE-ID=CDP.EL2> 949 * @see BaseType#enumStrList(String) 950 */ 951 public final String origin; 952 953 /** Associated style declaration. */ 954 public final CSS.CSSStyle style; 955 956 /** <CODE>[No Description Provided by Google]</CODE> */ 957 public final boolean active; 958 959 /** Constructor. Please review this class' fields for documentation. */ 960 public CSSPositionTryRule( 961 ReadOnlyList<Boolean> isPresent, Value name, String styleSheetId, String origin, 962 CSSStyle style, boolean active 963 ) 964 { 965 super(singleton, Domains.CSS, "CSSPositionTryRule", 5); 966 967 this.name = name; 968 this.styleSheetId = styleSheetId; 969 this.origin = origin; 970 this.style = style; 971 this.active = active; 972 973 this.isPresent = (isPresent == null) 974 ? singleton.generateIsPresentList(this) 975 : THROWS.check(isPresent, 5, "CSS.CSSPositionTryRule"); 976 } 977 978 /** Creates an instance of this class from a {@link JsonObject}.*/ 979 public static CSSPositionTryRule fromJSON(JsonObject jo) 980 { return singleton.fromJSON(jo); } 981 982 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 983 public static NestedDescriptor<CSSPositionTryRule> descriptor() 984 { return singleton.descriptor(); } 985 } 986 987 /** 988 * CSS property declaration data. 989 * 990 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 991 */ 992 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 993 public static class CSSProperty 994 extends BaseType<CSSProperty> 995 implements java.io.Serializable 996 { 997 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 998 protected static final long serialVersionUID = 1; 999 1000 private static final NestedHelper<CSS.CSSProperty> singleton = 1001 Torello.Browser.BrowserAPI.NestedHelpers.Types. 1002 CSS$$CSSProperty$$.singleton; 1003 1004 /** The property name. */ 1005 public final String name; 1006 1007 /** The property value. */ 1008 public final String value; 1009 1010 /** 1011 * Whether the property has "!important" annotation (implies <CODE>false</CODE> if absent). 1012 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1013 */ 1014 public final Boolean important; 1015 1016 /** 1017 * Whether the property is implicit (implies <CODE>false</CODE> if absent). 1018 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1019 */ 1020 public final Boolean implicit; 1021 1022 /** 1023 * The full property text as specified in the style. 1024 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1025 */ 1026 public final String text; 1027 1028 /** 1029 * Whether the property is understood by the browser (implies <CODE>true</CODE> if absent). 1030 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1031 */ 1032 public final Boolean parsedOk; 1033 1034 /** 1035 * Whether the property is disabled by the user (present for source-based properties only). 1036 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1037 */ 1038 public final Boolean disabled; 1039 1040 /** 1041 * The entire property range in the enclosing style declaration (if available). 1042 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1043 */ 1044 public final CSS.SourceRange range; 1045 1046 /** 1047 * Parsed longhand components of this property if it is a shorthand. 1048 * This field will be empty if the given property is not a shorthand. 1049 * <BR /><B CLASS=Opt-Top>OPTIONAL</B><B CLASS=Exp-Top>EXPERIMENTAL</B> 1050 */ 1051 public final CSS.CSSProperty[] longhandProperties; 1052 1053 /** Constructor. Please review this class' fields for documentation. */ 1054 public CSSProperty( 1055 ReadOnlyList<Boolean> isPresent, String name, String value, Boolean important, 1056 Boolean implicit, String text, Boolean parsedOk, Boolean disabled, 1057 SourceRange range, CSSProperty[] longhandProperties 1058 ) 1059 { 1060 super(singleton, Domains.CSS, "CSSProperty", 9); 1061 1062 this.name = name; 1063 this.value = value; 1064 this.important = important; 1065 this.implicit = implicit; 1066 this.text = text; 1067 this.parsedOk = parsedOk; 1068 this.disabled = disabled; 1069 this.range = range; 1070 this.longhandProperties = longhandProperties; 1071 1072 this.isPresent = (isPresent == null) 1073 ? singleton.generateIsPresentList(this) 1074 : THROWS.check(isPresent, 9, "CSS.CSSProperty"); 1075 } 1076 1077 /** Creates an instance of this class from a {@link JsonObject}.*/ 1078 public static CSSProperty fromJSON(JsonObject jo) 1079 { return singleton.fromJSON(jo); } 1080 1081 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 1082 public static NestedDescriptor<CSSProperty> descriptor() 1083 { return singleton.descriptor(); } 1084 } 1085 1086 /** 1087 * Representation of a custom property registration through CSS.registerProperty 1088 * 1089 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 1090 */ 1091 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 1092 public static class CSSPropertyRegistration 1093 extends BaseType<CSSPropertyRegistration> 1094 implements java.io.Serializable 1095 { 1096 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 1097 protected static final long serialVersionUID = 1; 1098 1099 private static final NestedHelper<CSS.CSSPropertyRegistration> singleton = 1100 Torello.Browser.BrowserAPI.NestedHelpers.Types. 1101 CSS$$CSSPropertyRegistration$$.singleton; 1102 1103 /** <CODE>[No Description Provided by Google]</CODE> */ 1104 public final String propertyName; 1105 1106 /** 1107 * <CODE>[No Description Provided by Google]</CODE> 1108 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1109 */ 1110 public final CSS.Value initialValue; 1111 1112 /** <CODE>[No Description Provided by Google]</CODE> */ 1113 public final boolean inherits; 1114 1115 /** <CODE>[No Description Provided by Google]</CODE> */ 1116 public final String syntax; 1117 1118 /** Constructor. Please review this class' fields for documentation. */ 1119 public CSSPropertyRegistration( 1120 ReadOnlyList<Boolean> isPresent, String propertyName, Value initialValue, 1121 boolean inherits, String syntax 1122 ) 1123 { 1124 super(singleton, Domains.CSS, "CSSPropertyRegistration", 4); 1125 1126 this.propertyName = propertyName; 1127 this.initialValue = initialValue; 1128 this.inherits = inherits; 1129 this.syntax = syntax; 1130 1131 this.isPresent = (isPresent == null) 1132 ? singleton.generateIsPresentList(this) 1133 : THROWS.check(isPresent, 4, "CSS.CSSPropertyRegistration"); 1134 } 1135 1136 /** Creates an instance of this class from a {@link JsonObject}.*/ 1137 public static CSSPropertyRegistration fromJSON(JsonObject jo) 1138 { return singleton.fromJSON(jo); } 1139 1140 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 1141 public static NestedDescriptor<CSSPropertyRegistration> descriptor() 1142 { return singleton.descriptor(); } 1143 } 1144 1145 /** 1146 * CSS property at-rule representation. 1147 * 1148 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 1149 */ 1150 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 1151 public static class CSSPropertyRule 1152 extends BaseType<CSSPropertyRule> 1153 implements java.io.Serializable 1154 { 1155 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 1156 protected static final long serialVersionUID = 1; 1157 1158 private static final NestedHelper<CSS.CSSPropertyRule> singleton = 1159 Torello.Browser.BrowserAPI.NestedHelpers.Types. 1160 CSS$$CSSPropertyRule$$.singleton; 1161 1162 /** 1163 * The css style sheet identifier (absent for user agent stylesheet and user-specified 1164 * stylesheet rules) this rule came from. 1165 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1166 */ 1167 public final String styleSheetId; 1168 1169 /** 1170 * Parent stylesheet's origin. 1171 * <EMBED CLASS='external-html' DATA-D=CSS DATA-C=StyleSheetOrigin DATA-F=origin DATA-FILE-ID=CDP.EL2> 1172 * @see BaseType#enumStrList(String) 1173 */ 1174 public final String origin; 1175 1176 /** Associated property name. */ 1177 public final CSS.Value propertyName; 1178 1179 /** Associated style declaration. */ 1180 public final CSS.CSSStyle style; 1181 1182 /** Constructor. Please review this class' fields for documentation. */ 1183 public CSSPropertyRule( 1184 ReadOnlyList<Boolean> isPresent, String styleSheetId, String origin, 1185 Value propertyName, CSSStyle style 1186 ) 1187 { 1188 super(singleton, Domains.CSS, "CSSPropertyRule", 4); 1189 1190 this.styleSheetId = styleSheetId; 1191 this.origin = origin; 1192 this.propertyName = propertyName; 1193 this.style = style; 1194 1195 this.isPresent = (isPresent == null) 1196 ? singleton.generateIsPresentList(this) 1197 : THROWS.check(isPresent, 4, "CSS.CSSPropertyRule"); 1198 } 1199 1200 /** Creates an instance of this class from a {@link JsonObject}.*/ 1201 public static CSSPropertyRule fromJSON(JsonObject jo) 1202 { return singleton.fromJSON(jo); } 1203 1204 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 1205 public static NestedDescriptor<CSSPropertyRule> descriptor() 1206 { return singleton.descriptor(); } 1207 } 1208 1209 /** 1210 * CSS rule representation. 1211 * 1212 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 1213 */ 1214 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 1215 public static class CSSRule 1216 extends BaseType<CSSRule> 1217 implements java.io.Serializable 1218 { 1219 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 1220 protected static final long serialVersionUID = 1; 1221 1222 private static final NestedHelper<CSS.CSSRule> singleton = 1223 Torello.Browser.BrowserAPI.NestedHelpers.Types. 1224 CSS$$CSSRule$$.singleton; 1225 1226 /** 1227 * The css style sheet identifier (absent for user agent stylesheet and user-specified 1228 * stylesheet rules) this rule came from. 1229 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1230 */ 1231 public final String styleSheetId; 1232 1233 /** Rule selector data. */ 1234 public final CSS.SelectorList selectorList; 1235 1236 /** 1237 * Array of selectors from ancestor style rules, sorted by distance from the current rule. 1238 * <BR /><B CLASS=Opt-Top>OPTIONAL</B><B CLASS=Exp-Top>EXPERIMENTAL</B> 1239 */ 1240 public final String[] nestingSelectors; 1241 1242 /** 1243 * Parent stylesheet's origin. 1244 * <EMBED CLASS='external-html' DATA-D=CSS DATA-C=StyleSheetOrigin DATA-F=origin DATA-FILE-ID=CDP.EL2> 1245 * @see BaseType#enumStrList(String) 1246 */ 1247 public final String origin; 1248 1249 /** Associated style declaration. */ 1250 public final CSS.CSSStyle style; 1251 1252 /** 1253 * Media list array (for rules involving media queries). The array enumerates media queries 1254 * starting with the innermost one, going outwards. 1255 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1256 */ 1257 public final CSS.CSSMedia[] media; 1258 1259 /** 1260 * Container query list array (for rules involving container queries). 1261 * The array enumerates container queries starting with the innermost one, going outwards. 1262 * <BR /><B CLASS=Opt-Top>OPTIONAL</B><B CLASS=Exp-Top>EXPERIMENTAL</B> 1263 */ 1264 public final CSS.CSSContainerQuery[] containerQueries; 1265 1266 /** 1267 * @supports CSS at-rule array. 1268 * The array enumerates @supports at-rules starting with the innermost one, going outwards. 1269 * <BR /><B CLASS=Opt-Top>OPTIONAL</B><B CLASS=Exp-Top>EXPERIMENTAL</B> 1270 */ 1271 public final CSS.CSSSupports[] supports; 1272 1273 /** 1274 * Cascade layer array. Contains the layer hierarchy that this rule belongs to starting 1275 * with the innermost layer and going outwards. 1276 * <BR /><B CLASS=Opt-Top>OPTIONAL</B><B CLASS=Exp-Top>EXPERIMENTAL</B> 1277 */ 1278 public final CSS.CSSLayer[] layers; 1279 1280 /** 1281 * @scope CSS at-rule array. 1282 * The array enumerates @scope at-rules starting with the innermost one, going outwards. 1283 * <BR /><B CLASS=Opt-Top>OPTIONAL</B><B CLASS=Exp-Top>EXPERIMENTAL</B> 1284 */ 1285 public final CSS.CSSScope[] scopes; 1286 1287 /** 1288 * The array keeps the types of ancestor CSSRules from the innermost going outwards. 1289 * <BR /><B CLASS=Opt-Top>OPTIONAL</B><B CLASS=Exp-Top>EXPERIMENTAL</B> 1290 * <EMBED CLASS='external-html' DATA-D=CSS DATA-C=CSSRuleType DATA-F=ruleTypes DATA-FILE-ID=CDP.EL2> 1291 * @see BaseType#enumStrList(String) 1292 */ 1293 public final String[] ruleTypes; 1294 1295 /** 1296 * @starting-style CSS at-rule array. 1297 * The array enumerates @starting-style at-rules starting with the innermost one, going outwards. 1298 * <BR /><B CLASS=Opt-Top>OPTIONAL</B><B CLASS=Exp-Top>EXPERIMENTAL</B> 1299 */ 1300 public final CSS.CSSStartingStyle[] startingStyles; 1301 1302 /** Constructor. Please review this class' fields for documentation. */ 1303 public CSSRule( 1304 ReadOnlyList<Boolean> isPresent, String styleSheetId, SelectorList selectorList, 1305 String[] nestingSelectors, String origin, CSSStyle style, CSSMedia[] media, 1306 CSSContainerQuery[] containerQueries, CSSSupports[] supports, CSSLayer[] layers, 1307 CSSScope[] scopes, String[] ruleTypes, CSSStartingStyle[] startingStyles 1308 ) 1309 { 1310 super(singleton, Domains.CSS, "CSSRule", 12); 1311 1312 this.styleSheetId = styleSheetId; 1313 this.selectorList = selectorList; 1314 this.nestingSelectors = nestingSelectors; 1315 this.origin = origin; 1316 this.style = style; 1317 this.media = media; 1318 this.containerQueries = containerQueries; 1319 this.supports = supports; 1320 this.layers = layers; 1321 this.scopes = scopes; 1322 this.ruleTypes = ruleTypes; 1323 this.startingStyles = startingStyles; 1324 1325 this.isPresent = (isPresent == null) 1326 ? singleton.generateIsPresentList(this) 1327 : THROWS.check(isPresent, 12, "CSS.CSSRule"); 1328 } 1329 1330 /** Creates an instance of this class from a {@link JsonObject}.*/ 1331 public static CSSRule fromJSON(JsonObject jo) 1332 { return singleton.fromJSON(jo); } 1333 1334 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 1335 public static NestedDescriptor<CSSRule> descriptor() 1336 { return singleton.descriptor(); } 1337 } 1338 1339 /** 1340 * CSS Scope at-rule descriptor. 1341 * 1342 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 1343 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 1344 */ 1345 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 1346 public static class CSSScope 1347 extends BaseType<CSSScope> 1348 implements java.io.Serializable 1349 { 1350 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 1351 protected static final long serialVersionUID = 1; 1352 1353 private static final NestedHelper<CSS.CSSScope> singleton = 1354 Torello.Browser.BrowserAPI.NestedHelpers.Types. 1355 CSS$$CSSScope$$.singleton; 1356 1357 /** Scope rule text. */ 1358 public final String text; 1359 1360 /** 1361 * The associated rule header range in the enclosing stylesheet (if 1362 * available). 1363 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1364 */ 1365 public final CSS.SourceRange range; 1366 1367 /** 1368 * Identifier of the stylesheet containing this object (if exists). 1369 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1370 */ 1371 public final String styleSheetId; 1372 1373 /** Constructor. Please review this class' fields for documentation. */ 1374 public CSSScope 1375 (ReadOnlyList<Boolean> isPresent, String text, SourceRange range, String styleSheetId) 1376 { 1377 super(singleton, Domains.CSS, "CSSScope", 3); 1378 1379 this.text = text; 1380 this.range = range; 1381 this.styleSheetId = styleSheetId; 1382 1383 this.isPresent = (isPresent == null) 1384 ? singleton.generateIsPresentList(this) 1385 : THROWS.check(isPresent, 3, "CSS.CSSScope"); 1386 } 1387 1388 /** Creates an instance of this class from a {@link JsonObject}.*/ 1389 public static CSSScope fromJSON(JsonObject jo) 1390 { return singleton.fromJSON(jo); } 1391 1392 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 1393 public static NestedDescriptor<CSSScope> descriptor() 1394 { return singleton.descriptor(); } 1395 } 1396 1397 /** 1398 * CSS Starting Style at-rule descriptor. 1399 * 1400 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 1401 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 1402 */ 1403 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 1404 public static class CSSStartingStyle 1405 extends BaseType<CSSStartingStyle> 1406 implements java.io.Serializable 1407 { 1408 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 1409 protected static final long serialVersionUID = 1; 1410 1411 private static final NestedHelper<CSS.CSSStartingStyle> singleton = 1412 Torello.Browser.BrowserAPI.NestedHelpers.Types. 1413 CSS$$CSSStartingStyle$$.singleton; 1414 1415 /** 1416 * The associated rule header range in the enclosing stylesheet (if 1417 * available). 1418 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1419 */ 1420 public final CSS.SourceRange range; 1421 1422 /** 1423 * Identifier of the stylesheet containing this object (if exists). 1424 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1425 */ 1426 public final String styleSheetId; 1427 1428 /** Constructor. Please review this class' fields for documentation. */ 1429 public CSSStartingStyle 1430 (ReadOnlyList<Boolean> isPresent, SourceRange range, String styleSheetId) 1431 { 1432 super(singleton, Domains.CSS, "CSSStartingStyle", 2); 1433 1434 this.range = range; 1435 this.styleSheetId = styleSheetId; 1436 1437 this.isPresent = (isPresent == null) 1438 ? singleton.generateIsPresentList(this) 1439 : THROWS.check(isPresent, 2, "CSS.CSSStartingStyle"); 1440 } 1441 1442 /** Creates an instance of this class from a {@link JsonObject}.*/ 1443 public static CSSStartingStyle fromJSON(JsonObject jo) 1444 { return singleton.fromJSON(jo); } 1445 1446 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 1447 public static NestedDescriptor<CSSStartingStyle> descriptor() 1448 { return singleton.descriptor(); } 1449 } 1450 1451 /** 1452 * CSS style representation. 1453 * 1454 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 1455 */ 1456 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 1457 public static class CSSStyle 1458 extends BaseType<CSSStyle> 1459 implements java.io.Serializable 1460 { 1461 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 1462 protected static final long serialVersionUID = 1; 1463 1464 private static final NestedHelper<CSS.CSSStyle> singleton = 1465 Torello.Browser.BrowserAPI.NestedHelpers.Types. 1466 CSS$$CSSStyle$$.singleton; 1467 1468 /** 1469 * The css style sheet identifier (absent for user agent stylesheet and user-specified 1470 * stylesheet rules) this rule came from. 1471 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1472 */ 1473 public final String styleSheetId; 1474 1475 /** CSS properties in the style. */ 1476 public final CSS.CSSProperty[] cssProperties; 1477 1478 /** Computed values for all shorthands found in the style. */ 1479 public final CSS.ShorthandEntry[] shorthandEntries; 1480 1481 /** 1482 * Style declaration text (if available). 1483 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1484 */ 1485 public final String cssText; 1486 1487 /** 1488 * Style declaration range in the enclosing stylesheet (if available). 1489 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1490 */ 1491 public final CSS.SourceRange range; 1492 1493 /** Constructor. Please review this class' fields for documentation. */ 1494 public CSSStyle( 1495 ReadOnlyList<Boolean> isPresent, String styleSheetId, CSSProperty[] cssProperties, 1496 ShorthandEntry[] shorthandEntries, String cssText, SourceRange range 1497 ) 1498 { 1499 super(singleton, Domains.CSS, "CSSStyle", 5); 1500 1501 this.styleSheetId = styleSheetId; 1502 this.cssProperties = cssProperties; 1503 this.shorthandEntries = shorthandEntries; 1504 this.cssText = cssText; 1505 this.range = range; 1506 1507 this.isPresent = (isPresent == null) 1508 ? singleton.generateIsPresentList(this) 1509 : THROWS.check(isPresent, 5, "CSS.CSSStyle"); 1510 } 1511 1512 /** Creates an instance of this class from a {@link JsonObject}.*/ 1513 public static CSSStyle fromJSON(JsonObject jo) 1514 { return singleton.fromJSON(jo); } 1515 1516 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 1517 public static NestedDescriptor<CSSStyle> descriptor() 1518 { return singleton.descriptor(); } 1519 } 1520 1521 /** 1522 * CSS stylesheet metainformation. 1523 * 1524 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 1525 */ 1526 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 1527 public static class CSSStyleSheetHeader 1528 extends BaseType<CSSStyleSheetHeader> 1529 implements java.io.Serializable 1530 { 1531 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 1532 protected static final long serialVersionUID = 1; 1533 1534 private static final NestedHelper<CSS.CSSStyleSheetHeader> singleton = 1535 Torello.Browser.BrowserAPI.NestedHelpers.Types. 1536 CSS$$CSSStyleSheetHeader$$.singleton; 1537 1538 /** The stylesheet identifier. */ 1539 public final String styleSheetId; 1540 1541 /** Owner frame identifier. */ 1542 public final String frameId; 1543 1544 /** 1545 * Stylesheet resource URL. Empty if this is a constructed stylesheet created using 1546 * new CSSStyleSheet() (but non-empty if this is a constructed stylesheet imported 1547 * as a CSS module script). 1548 */ 1549 public final String sourceURL; 1550 1551 /** 1552 * URL of source map associated with the stylesheet (if any). 1553 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1554 */ 1555 public final String sourceMapURL; 1556 1557 /** 1558 * Stylesheet origin. 1559 * <EMBED CLASS='external-html' DATA-D=CSS DATA-C=StyleSheetOrigin DATA-F=origin DATA-FILE-ID=CDP.EL2> 1560 * @see BaseType#enumStrList(String) 1561 */ 1562 public final String origin; 1563 1564 /** Stylesheet title. */ 1565 public final String title; 1566 1567 /** 1568 * The backend id for the owner node of the stylesheet. 1569 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1570 */ 1571 public final Integer ownerNode; 1572 1573 /** Denotes whether the stylesheet is disabled. */ 1574 public final boolean disabled; 1575 1576 /** 1577 * Whether the sourceURL field value comes from the sourceURL comment. 1578 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1579 */ 1580 public final Boolean hasSourceURL; 1581 1582 /** 1583 * Whether this stylesheet is created for STYLE tag by parser. This flag is not set for 1584 * document.written STYLE tags. 1585 */ 1586 public final boolean isInline; 1587 1588 /** 1589 * Whether this stylesheet is mutable. Inline stylesheets become mutable 1590 * after they have been modified via CSSOM API. 1591 * <CODE>{@code <link>}</CODE> element's stylesheets become mutable only if DevTools modifies them. 1592 * Constructed stylesheets (new CSSStyleSheet()) are mutable immediately after creation. 1593 */ 1594 public final boolean isMutable; 1595 1596 /** 1597 * True if this stylesheet is created through new CSSStyleSheet() or imported as a 1598 * CSS module script. 1599 */ 1600 public final boolean isConstructed; 1601 1602 /** Line offset of the stylesheet within the resource (zero based). */ 1603 public final Number startLine; 1604 1605 /** Column offset of the stylesheet within the resource (zero based). */ 1606 public final Number startColumn; 1607 1608 /** Size of the content (in characters). */ 1609 public final Number length; 1610 1611 /** Line offset of the end of the stylesheet within the resource (zero based). */ 1612 public final Number endLine; 1613 1614 /** Column offset of the end of the stylesheet within the resource (zero based). */ 1615 public final Number endColumn; 1616 1617 /** 1618 * If the style sheet was loaded from a network resource, this indicates when the resource failed to load 1619 * <BR /><B CLASS=Opt-Top>OPTIONAL</B><B CLASS=Exp-Top>EXPERIMENTAL</B> 1620 */ 1621 public final Boolean loadingFailed; 1622 1623 /** Constructor. Please review this class' fields for documentation. */ 1624 public CSSStyleSheetHeader( 1625 ReadOnlyList<Boolean> isPresent, String styleSheetId, String frameId, 1626 String sourceURL, String sourceMapURL, String origin, String title, 1627 Integer ownerNode, boolean disabled, Boolean hasSourceURL, boolean isInline, 1628 boolean isMutable, boolean isConstructed, Number startLine, Number startColumn, 1629 Number length, Number endLine, Number endColumn, Boolean loadingFailed 1630 ) 1631 { 1632 super(singleton, Domains.CSS, "CSSStyleSheetHeader", 18); 1633 1634 this.styleSheetId = styleSheetId; 1635 this.frameId = frameId; 1636 this.sourceURL = sourceURL; 1637 this.sourceMapURL = sourceMapURL; 1638 this.origin = origin; 1639 this.title = title; 1640 this.ownerNode = ownerNode; 1641 this.disabled = disabled; 1642 this.hasSourceURL = hasSourceURL; 1643 this.isInline = isInline; 1644 this.isMutable = isMutable; 1645 this.isConstructed = isConstructed; 1646 this.startLine = startLine; 1647 this.startColumn = startColumn; 1648 this.length = length; 1649 this.endLine = endLine; 1650 this.endColumn = endColumn; 1651 this.loadingFailed = loadingFailed; 1652 1653 this.isPresent = (isPresent == null) 1654 ? singleton.generateIsPresentList(this) 1655 : THROWS.check(isPresent, 18, "CSS.CSSStyleSheetHeader"); 1656 } 1657 1658 /** Creates an instance of this class from a {@link JsonObject}.*/ 1659 public static CSSStyleSheetHeader fromJSON(JsonObject jo) 1660 { return singleton.fromJSON(jo); } 1661 1662 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 1663 public static NestedDescriptor<CSSStyleSheetHeader> descriptor() 1664 { return singleton.descriptor(); } 1665 } 1666 1667 /** 1668 * CSS Supports at-rule descriptor. 1669 * 1670 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 1671 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 1672 */ 1673 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 1674 public static class CSSSupports 1675 extends BaseType<CSSSupports> 1676 implements java.io.Serializable 1677 { 1678 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 1679 protected static final long serialVersionUID = 1; 1680 1681 private static final NestedHelper<CSS.CSSSupports> singleton = 1682 Torello.Browser.BrowserAPI.NestedHelpers.Types. 1683 CSS$$CSSSupports$$.singleton; 1684 1685 /** Supports rule text. */ 1686 public final String text; 1687 1688 /** Whether the supports condition is satisfied. */ 1689 public final boolean active; 1690 1691 /** 1692 * The associated rule header range in the enclosing stylesheet (if 1693 * available). 1694 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1695 */ 1696 public final CSS.SourceRange range; 1697 1698 /** 1699 * Identifier of the stylesheet containing this object (if exists). 1700 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1701 */ 1702 public final String styleSheetId; 1703 1704 /** Constructor. Please review this class' fields for documentation. */ 1705 public CSSSupports( 1706 ReadOnlyList<Boolean> isPresent, String text, boolean active, SourceRange range, 1707 String styleSheetId 1708 ) 1709 { 1710 super(singleton, Domains.CSS, "CSSSupports", 4); 1711 1712 this.text = text; 1713 this.active = active; 1714 this.range = range; 1715 this.styleSheetId = styleSheetId; 1716 1717 this.isPresent = (isPresent == null) 1718 ? singleton.generateIsPresentList(this) 1719 : THROWS.check(isPresent, 4, "CSS.CSSSupports"); 1720 } 1721 1722 /** Creates an instance of this class from a {@link JsonObject}.*/ 1723 public static CSSSupports fromJSON(JsonObject jo) 1724 { return singleton.fromJSON(jo); } 1725 1726 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 1727 public static NestedDescriptor<CSSSupports> descriptor() 1728 { return singleton.descriptor(); } 1729 } 1730 1731 /** 1732 * CSS try rule representation. 1733 * 1734 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 1735 */ 1736 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 1737 public static class CSSTryRule 1738 extends BaseType<CSSTryRule> 1739 implements java.io.Serializable 1740 { 1741 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 1742 protected static final long serialVersionUID = 1; 1743 1744 private static final NestedHelper<CSS.CSSTryRule> singleton = 1745 Torello.Browser.BrowserAPI.NestedHelpers.Types. 1746 CSS$$CSSTryRule$$.singleton; 1747 1748 /** 1749 * The css style sheet identifier (absent for user agent stylesheet and user-specified 1750 * stylesheet rules) this rule came from. 1751 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1752 */ 1753 public final String styleSheetId; 1754 1755 /** 1756 * Parent stylesheet's origin. 1757 * <EMBED CLASS='external-html' DATA-D=CSS DATA-C=StyleSheetOrigin DATA-F=origin DATA-FILE-ID=CDP.EL2> 1758 * @see BaseType#enumStrList(String) 1759 */ 1760 public final String origin; 1761 1762 /** Associated style declaration. */ 1763 public final CSS.CSSStyle style; 1764 1765 /** Constructor. Please review this class' fields for documentation. */ 1766 public CSSTryRule 1767 (ReadOnlyList<Boolean> isPresent, String styleSheetId, String origin, CSSStyle style) 1768 { 1769 super(singleton, Domains.CSS, "CSSTryRule", 3); 1770 1771 this.styleSheetId = styleSheetId; 1772 this.origin = origin; 1773 this.style = style; 1774 1775 this.isPresent = (isPresent == null) 1776 ? singleton.generateIsPresentList(this) 1777 : THROWS.check(isPresent, 3, "CSS.CSSTryRule"); 1778 } 1779 1780 /** Creates an instance of this class from a {@link JsonObject}.*/ 1781 public static CSSTryRule fromJSON(JsonObject jo) 1782 { return singleton.fromJSON(jo); } 1783 1784 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 1785 public static NestedDescriptor<CSSTryRule> descriptor() 1786 { return singleton.descriptor(); } 1787 } 1788 1789 /** 1790 * Properties of a web font: https://www.w3.org/TR/2008/REC-CSS2-20080411/fonts.html#font-descriptions 1791 * and additional information such as platformFontFamily and fontVariationAxes. 1792 * 1793 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 1794 */ 1795 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 1796 public static class FontFace 1797 extends BaseType<FontFace> 1798 implements java.io.Serializable 1799 { 1800 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 1801 protected static final long serialVersionUID = 1; 1802 1803 private static final NestedHelper<CSS.FontFace> singleton = 1804 Torello.Browser.BrowserAPI.NestedHelpers.Types. 1805 CSS$$FontFace$$.singleton; 1806 1807 /** The font-family. */ 1808 public final String fontFamily; 1809 1810 /** The font-style. */ 1811 public final String fontStyle; 1812 1813 /** The font-variant. */ 1814 public final String fontVariant; 1815 1816 /** The font-weight. */ 1817 public final String fontWeight; 1818 1819 /** The font-stretch. */ 1820 public final String fontStretch; 1821 1822 /** The font-display. */ 1823 public final String fontDisplay; 1824 1825 /** The unicode-range. */ 1826 public final String unicodeRange; 1827 1828 /** The src. */ 1829 public final String src; 1830 1831 /** The resolved platform font family */ 1832 public final String platformFontFamily; 1833 1834 /** 1835 * Available variation settings (a.k.a. "axes"). 1836 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1837 */ 1838 public final CSS.FontVariationAxis[] fontVariationAxes; 1839 1840 /** Constructor. Please review this class' fields for documentation. */ 1841 public FontFace( 1842 ReadOnlyList<Boolean> isPresent, String fontFamily, String fontStyle, 1843 String fontVariant, String fontWeight, String fontStretch, String fontDisplay, 1844 String unicodeRange, String src, String platformFontFamily, 1845 FontVariationAxis[] fontVariationAxes 1846 ) 1847 { 1848 super(singleton, Domains.CSS, "FontFace", 10); 1849 1850 this.fontFamily = fontFamily; 1851 this.fontStyle = fontStyle; 1852 this.fontVariant = fontVariant; 1853 this.fontWeight = fontWeight; 1854 this.fontStretch = fontStretch; 1855 this.fontDisplay = fontDisplay; 1856 this.unicodeRange = unicodeRange; 1857 this.src = src; 1858 this.platformFontFamily = platformFontFamily; 1859 this.fontVariationAxes = fontVariationAxes; 1860 1861 this.isPresent = (isPresent == null) 1862 ? singleton.generateIsPresentList(this) 1863 : THROWS.check(isPresent, 10, "CSS.FontFace"); 1864 } 1865 1866 /** Creates an instance of this class from a {@link JsonObject}.*/ 1867 public static FontFace fromJSON(JsonObject jo) 1868 { return singleton.fromJSON(jo); } 1869 1870 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 1871 public static NestedDescriptor<FontFace> descriptor() 1872 { return singleton.descriptor(); } 1873 } 1874 1875 /** 1876 * Information about font variation axes for variable fonts 1877 * 1878 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 1879 */ 1880 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 1881 public static class FontVariationAxis 1882 extends BaseType<FontVariationAxis> 1883 implements java.io.Serializable 1884 { 1885 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 1886 protected static final long serialVersionUID = 1; 1887 1888 private static final NestedHelper<CSS.FontVariationAxis> singleton = 1889 Torello.Browser.BrowserAPI.NestedHelpers.Types. 1890 CSS$$FontVariationAxis$$.singleton; 1891 1892 /** The font-variation-setting tag (a.k.a. "axis tag"). */ 1893 public final String tag; 1894 1895 /** Human-readable variation name in the default language (normally, "en"). */ 1896 public final String name; 1897 1898 /** The minimum value (inclusive) the font supports for this tag. */ 1899 public final Number minValue; 1900 1901 /** The maximum value (inclusive) the font supports for this tag. */ 1902 public final Number maxValue; 1903 1904 /** The default value. */ 1905 public final Number defaultValue; 1906 1907 /** Constructor. Please review this class' fields for documentation. */ 1908 public FontVariationAxis( 1909 ReadOnlyList<Boolean> isPresent, String tag, String name, Number minValue, 1910 Number maxValue, Number defaultValue 1911 ) 1912 { 1913 super(singleton, Domains.CSS, "FontVariationAxis", 5); 1914 1915 this.tag = tag; 1916 this.name = name; 1917 this.minValue = minValue; 1918 this.maxValue = maxValue; 1919 this.defaultValue = defaultValue; 1920 1921 this.isPresent = (isPresent == null) 1922 ? singleton.generateIsPresentList(this) 1923 : THROWS.check(isPresent, 5, "CSS.FontVariationAxis"); 1924 } 1925 1926 /** Creates an instance of this class from a {@link JsonObject}.*/ 1927 public static FontVariationAxis fromJSON(JsonObject jo) 1928 { return singleton.fromJSON(jo); } 1929 1930 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 1931 public static NestedDescriptor<FontVariationAxis> descriptor() 1932 { return singleton.descriptor(); } 1933 } 1934 1935 /** 1936 * Inherited CSS style collection for animated styles from ancestor node. 1937 * 1938 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 1939 */ 1940 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 1941 public static class InheritedAnimatedStyleEntry 1942 extends BaseType<InheritedAnimatedStyleEntry> 1943 implements java.io.Serializable 1944 { 1945 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 1946 protected static final long serialVersionUID = 1; 1947 1948 private static final NestedHelper<CSS.InheritedAnimatedStyleEntry> singleton = 1949 Torello.Browser.BrowserAPI.NestedHelpers.Types. 1950 CSS$$InheritedAnimatedStyleEntry$$.singleton; 1951 1952 /** 1953 * Styles coming from the animations of the ancestor, if any, in the style inheritance chain. 1954 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1955 */ 1956 public final CSS.CSSAnimationStyle[] animationStyles; 1957 1958 /** 1959 * The style coming from the transitions of the ancestor, if any, in the style inheritance chain. 1960 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 1961 */ 1962 public final CSS.CSSStyle transitionsStyle; 1963 1964 /** Constructor. Please review this class' fields for documentation. */ 1965 public InheritedAnimatedStyleEntry( 1966 ReadOnlyList<Boolean> isPresent, CSSAnimationStyle[] animationStyles, 1967 CSSStyle transitionsStyle 1968 ) 1969 { 1970 super(singleton, Domains.CSS, "InheritedAnimatedStyleEntry", 2); 1971 1972 this.animationStyles = animationStyles; 1973 this.transitionsStyle = transitionsStyle; 1974 1975 this.isPresent = (isPresent == null) 1976 ? singleton.generateIsPresentList(this) 1977 : THROWS.check(isPresent, 2, "CSS.InheritedAnimatedStyleEntry"); 1978 } 1979 1980 /** Creates an instance of this class from a {@link JsonObject}.*/ 1981 public static InheritedAnimatedStyleEntry fromJSON(JsonObject jo) 1982 { return singleton.fromJSON(jo); } 1983 1984 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 1985 public static NestedDescriptor<InheritedAnimatedStyleEntry> descriptor() 1986 { return singleton.descriptor(); } 1987 } 1988 1989 /** 1990 * Inherited pseudo element matches from pseudos of an ancestor node. 1991 * 1992 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 1993 */ 1994 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 1995 public static class InheritedPseudoElementMatches 1996 extends BaseType<InheritedPseudoElementMatches> 1997 implements java.io.Serializable 1998 { 1999 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2000 protected static final long serialVersionUID = 1; 2001 2002 private static final NestedHelper<CSS.InheritedPseudoElementMatches> singleton = 2003 Torello.Browser.BrowserAPI.NestedHelpers.Types. 2004 CSS$$InheritedPseudoElementMatches$$.singleton; 2005 2006 /** Matches of pseudo styles from the pseudos of an ancestor node. */ 2007 public final CSS.PseudoElementMatches[] pseudoElements; 2008 2009 /** Constructor. Please review this class' fields for documentation. */ 2010 public InheritedPseudoElementMatches 2011 (ReadOnlyList<Boolean> isPresent, PseudoElementMatches[] pseudoElements) 2012 { 2013 super(singleton, Domains.CSS, "InheritedPseudoElementMatches", 1); 2014 2015 this.pseudoElements = pseudoElements; 2016 2017 this.isPresent = (isPresent == null) 2018 ? singleton.generateIsPresentList(this) 2019 : THROWS.check(isPresent, 1, "CSS.InheritedPseudoElementMatches"); 2020 } 2021 2022 /** Creates an instance of this class from a {@link JsonObject}.*/ 2023 public static InheritedPseudoElementMatches fromJSON(JsonObject jo) 2024 { return singleton.fromJSON(jo); } 2025 2026 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 2027 public static NestedDescriptor<InheritedPseudoElementMatches> descriptor() 2028 { return singleton.descriptor(); } 2029 } 2030 2031 /** 2032 * Inherited CSS rule collection from ancestor node. 2033 * 2034 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 2035 */ 2036 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 2037 public static class InheritedStyleEntry 2038 extends BaseType<InheritedStyleEntry> 2039 implements java.io.Serializable 2040 { 2041 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2042 protected static final long serialVersionUID = 1; 2043 2044 private static final NestedHelper<CSS.InheritedStyleEntry> singleton = 2045 Torello.Browser.BrowserAPI.NestedHelpers.Types. 2046 CSS$$InheritedStyleEntry$$.singleton; 2047 2048 /** 2049 * The ancestor node's inline style, if any, in the style inheritance chain. 2050 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2051 */ 2052 public final CSS.CSSStyle inlineStyle; 2053 2054 /** Matches of CSS rules matching the ancestor node in the style inheritance chain. */ 2055 public final CSS.RuleMatch[] matchedCSSRules; 2056 2057 /** Constructor. Please review this class' fields for documentation. */ 2058 public InheritedStyleEntry 2059 (ReadOnlyList<Boolean> isPresent, CSSStyle inlineStyle, RuleMatch[] matchedCSSRules) 2060 { 2061 super(singleton, Domains.CSS, "InheritedStyleEntry", 2); 2062 2063 this.inlineStyle = inlineStyle; 2064 this.matchedCSSRules = matchedCSSRules; 2065 2066 this.isPresent = (isPresent == null) 2067 ? singleton.generateIsPresentList(this) 2068 : THROWS.check(isPresent, 2, "CSS.InheritedStyleEntry"); 2069 } 2070 2071 /** Creates an instance of this class from a {@link JsonObject}.*/ 2072 public static InheritedStyleEntry fromJSON(JsonObject jo) 2073 { return singleton.fromJSON(jo); } 2074 2075 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 2076 public static NestedDescriptor<InheritedStyleEntry> descriptor() 2077 { return singleton.descriptor(); } 2078 } 2079 2080 /** 2081 * Media query descriptor. 2082 * 2083 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 2084 */ 2085 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 2086 public static class MediaQuery 2087 extends BaseType<MediaQuery> 2088 implements java.io.Serializable 2089 { 2090 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2091 protected static final long serialVersionUID = 1; 2092 2093 private static final NestedHelper<CSS.MediaQuery> singleton = 2094 Torello.Browser.BrowserAPI.NestedHelpers.Types. 2095 CSS$$MediaQuery$$.singleton; 2096 2097 /** Array of media query expressions. */ 2098 public final CSS.MediaQueryExpression[] expressions; 2099 2100 /** Whether the media query condition is satisfied. */ 2101 public final boolean active; 2102 2103 /** Constructor. Please review this class' fields for documentation. */ 2104 public MediaQuery 2105 (ReadOnlyList<Boolean> isPresent, MediaQueryExpression[] expressions, boolean active) 2106 { 2107 super(singleton, Domains.CSS, "MediaQuery", 2); 2108 2109 this.expressions = expressions; 2110 this.active = active; 2111 2112 this.isPresent = (isPresent == null) 2113 ? singleton.generateIsPresentList(this) 2114 : THROWS.check(isPresent, 2, "CSS.MediaQuery"); 2115 } 2116 2117 /** Creates an instance of this class from a {@link JsonObject}.*/ 2118 public static MediaQuery fromJSON(JsonObject jo) 2119 { return singleton.fromJSON(jo); } 2120 2121 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 2122 public static NestedDescriptor<MediaQuery> descriptor() 2123 { return singleton.descriptor(); } 2124 } 2125 2126 /** 2127 * Media query expression descriptor. 2128 * 2129 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 2130 */ 2131 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 2132 public static class MediaQueryExpression 2133 extends BaseType<MediaQueryExpression> 2134 implements java.io.Serializable 2135 { 2136 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2137 protected static final long serialVersionUID = 1; 2138 2139 private static final NestedHelper<CSS.MediaQueryExpression> singleton = 2140 Torello.Browser.BrowserAPI.NestedHelpers.Types. 2141 CSS$$MediaQueryExpression$$.singleton; 2142 2143 /** Media query expression value. */ 2144 public final Number value; 2145 2146 /** Media query expression units. */ 2147 public final String unit; 2148 2149 /** Media query expression feature. */ 2150 public final String feature; 2151 2152 /** 2153 * The associated range of the value text in the enclosing stylesheet (if available). 2154 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2155 */ 2156 public final CSS.SourceRange valueRange; 2157 2158 /** 2159 * Computed length of media query expression (if applicable). 2160 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2161 */ 2162 public final Number computedLength; 2163 2164 /** Constructor. Please review this class' fields for documentation. */ 2165 public MediaQueryExpression( 2166 ReadOnlyList<Boolean> isPresent, Number value, String unit, String feature, 2167 SourceRange valueRange, Number computedLength 2168 ) 2169 { 2170 super(singleton, Domains.CSS, "MediaQueryExpression", 5); 2171 2172 this.value = value; 2173 this.unit = unit; 2174 this.feature = feature; 2175 this.valueRange = valueRange; 2176 this.computedLength = computedLength; 2177 2178 this.isPresent = (isPresent == null) 2179 ? singleton.generateIsPresentList(this) 2180 : THROWS.check(isPresent, 5, "CSS.MediaQueryExpression"); 2181 } 2182 2183 /** Creates an instance of this class from a {@link JsonObject}.*/ 2184 public static MediaQueryExpression fromJSON(JsonObject jo) 2185 { return singleton.fromJSON(jo); } 2186 2187 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 2188 public static NestedDescriptor<MediaQueryExpression> descriptor() 2189 { return singleton.descriptor(); } 2190 } 2191 2192 /** 2193 * Information about amount of glyphs that were rendered with given font. 2194 * 2195 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 2196 */ 2197 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 2198 public static class PlatformFontUsage 2199 extends BaseType<PlatformFontUsage> 2200 implements java.io.Serializable 2201 { 2202 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2203 protected static final long serialVersionUID = 1; 2204 2205 private static final NestedHelper<CSS.PlatformFontUsage> singleton = 2206 Torello.Browser.BrowserAPI.NestedHelpers.Types. 2207 CSS$$PlatformFontUsage$$.singleton; 2208 2209 /** Font's family name reported by platform. */ 2210 public final String familyName; 2211 2212 /** Font's PostScript name reported by platform. */ 2213 public final String postScriptName; 2214 2215 /** Indicates if the font was downloaded or resolved locally. */ 2216 public final boolean isCustomFont; 2217 2218 /** Amount of glyphs that were rendered with this font. */ 2219 public final Number glyphCount; 2220 2221 /** Constructor. Please review this class' fields for documentation. */ 2222 public PlatformFontUsage( 2223 ReadOnlyList<Boolean> isPresent, String familyName, String postScriptName, 2224 boolean isCustomFont, Number glyphCount 2225 ) 2226 { 2227 super(singleton, Domains.CSS, "PlatformFontUsage", 4); 2228 2229 this.familyName = familyName; 2230 this.postScriptName = postScriptName; 2231 this.isCustomFont = isCustomFont; 2232 this.glyphCount = glyphCount; 2233 2234 this.isPresent = (isPresent == null) 2235 ? singleton.generateIsPresentList(this) 2236 : THROWS.check(isPresent, 4, "CSS.PlatformFontUsage"); 2237 } 2238 2239 /** Creates an instance of this class from a {@link JsonObject}.*/ 2240 public static PlatformFontUsage fromJSON(JsonObject jo) 2241 { return singleton.fromJSON(jo); } 2242 2243 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 2244 public static NestedDescriptor<PlatformFontUsage> descriptor() 2245 { return singleton.descriptor(); } 2246 } 2247 2248 /** 2249 * CSS rule collection for a single pseudo style. 2250 * 2251 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 2252 */ 2253 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 2254 public static class PseudoElementMatches 2255 extends BaseType<PseudoElementMatches> 2256 implements java.io.Serializable 2257 { 2258 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2259 protected static final long serialVersionUID = 1; 2260 2261 private static final NestedHelper<CSS.PseudoElementMatches> singleton = 2262 Torello.Browser.BrowserAPI.NestedHelpers.Types. 2263 CSS$$PseudoElementMatches$$.singleton; 2264 2265 /** 2266 * Pseudo element type. 2267 * <EMBED CLASS='external-html' DATA-D=DOM DATA-C=PseudoType DATA-F=pseudoType DATA-FILE-ID=CDP.EL2> 2268 * @see BaseType#enumStrList(String) 2269 */ 2270 public final String pseudoType; 2271 2272 /** 2273 * Pseudo element custom ident. 2274 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2275 */ 2276 public final String pseudoIdentifier; 2277 2278 /** Matches of CSS rules applicable to the pseudo style. */ 2279 public final CSS.RuleMatch[] matches; 2280 2281 /** Constructor. Please review this class' fields for documentation. */ 2282 public PseudoElementMatches( 2283 ReadOnlyList<Boolean> isPresent, String pseudoType, String pseudoIdentifier, 2284 RuleMatch[] matches 2285 ) 2286 { 2287 super(singleton, Domains.CSS, "PseudoElementMatches", 3); 2288 2289 this.pseudoType = pseudoType; 2290 this.pseudoIdentifier = pseudoIdentifier; 2291 this.matches = matches; 2292 2293 this.isPresent = (isPresent == null) 2294 ? singleton.generateIsPresentList(this) 2295 : THROWS.check(isPresent, 3, "CSS.PseudoElementMatches"); 2296 } 2297 2298 /** Creates an instance of this class from a {@link JsonObject}.*/ 2299 public static PseudoElementMatches fromJSON(JsonObject jo) 2300 { return singleton.fromJSON(jo); } 2301 2302 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 2303 public static NestedDescriptor<PseudoElementMatches> descriptor() 2304 { return singleton.descriptor(); } 2305 } 2306 2307 /** 2308 * Match data for a CSS rule. 2309 * 2310 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 2311 */ 2312 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 2313 public static class RuleMatch 2314 extends BaseType<RuleMatch> 2315 implements java.io.Serializable 2316 { 2317 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2318 protected static final long serialVersionUID = 1; 2319 2320 private static final NestedHelper<CSS.RuleMatch> singleton = 2321 Torello.Browser.BrowserAPI.NestedHelpers.Types. 2322 CSS$$RuleMatch$$.singleton; 2323 2324 /** CSS rule in the match. */ 2325 public final CSS.CSSRule rule; 2326 2327 /** Matching selector indices in the rule's selectorList selectors (0-based). */ 2328 public final int[] matchingSelectors; 2329 2330 /** Constructor. Please review this class' fields for documentation. */ 2331 public RuleMatch(ReadOnlyList<Boolean> isPresent, CSSRule rule, int[] matchingSelectors) 2332 { 2333 super(singleton, Domains.CSS, "RuleMatch", 2); 2334 2335 this.rule = rule; 2336 this.matchingSelectors = matchingSelectors; 2337 2338 this.isPresent = (isPresent == null) 2339 ? singleton.generateIsPresentList(this) 2340 : THROWS.check(isPresent, 2, "CSS.RuleMatch"); 2341 } 2342 2343 /** Creates an instance of this class from a {@link JsonObject}.*/ 2344 public static RuleMatch fromJSON(JsonObject jo) 2345 { return singleton.fromJSON(jo); } 2346 2347 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 2348 public static NestedDescriptor<RuleMatch> descriptor() 2349 { return singleton.descriptor(); } 2350 } 2351 2352 /** 2353 * CSS coverage information. 2354 * 2355 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 2356 */ 2357 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 2358 public static class RuleUsage 2359 extends BaseType<RuleUsage> 2360 implements java.io.Serializable 2361 { 2362 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2363 protected static final long serialVersionUID = 1; 2364 2365 private static final NestedHelper<CSS.RuleUsage> singleton = 2366 Torello.Browser.BrowserAPI.NestedHelpers.Types. 2367 CSS$$RuleUsage$$.singleton; 2368 2369 /** 2370 * The css style sheet identifier (absent for user agent stylesheet and user-specified 2371 * stylesheet rules) this rule came from. 2372 */ 2373 public final String styleSheetId; 2374 2375 /** Offset of the start of the rule (including selector) from the beginning of the stylesheet. */ 2376 public final Number startOffset; 2377 2378 /** Offset of the end of the rule body from the beginning of the stylesheet. */ 2379 public final Number endOffset; 2380 2381 /** Indicates whether the rule was actually used by some element in the page. */ 2382 public final boolean used; 2383 2384 /** Constructor. Please review this class' fields for documentation. */ 2385 public RuleUsage( 2386 ReadOnlyList<Boolean> isPresent, String styleSheetId, Number startOffset, 2387 Number endOffset, boolean used 2388 ) 2389 { 2390 super(singleton, Domains.CSS, "RuleUsage", 4); 2391 2392 this.styleSheetId = styleSheetId; 2393 this.startOffset = startOffset; 2394 this.endOffset = endOffset; 2395 this.used = used; 2396 2397 this.isPresent = (isPresent == null) 2398 ? singleton.generateIsPresentList(this) 2399 : THROWS.check(isPresent, 4, "CSS.RuleUsage"); 2400 } 2401 2402 /** Creates an instance of this class from a {@link JsonObject}.*/ 2403 public static RuleUsage fromJSON(JsonObject jo) 2404 { return singleton.fromJSON(jo); } 2405 2406 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 2407 public static NestedDescriptor<RuleUsage> descriptor() 2408 { return singleton.descriptor(); } 2409 } 2410 2411 /** 2412 * Selector list data. 2413 * 2414 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 2415 */ 2416 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 2417 public static class SelectorList 2418 extends BaseType<SelectorList> 2419 implements java.io.Serializable 2420 { 2421 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2422 protected static final long serialVersionUID = 1; 2423 2424 private static final NestedHelper<CSS.SelectorList> singleton = 2425 Torello.Browser.BrowserAPI.NestedHelpers.Types. 2426 CSS$$SelectorList$$.singleton; 2427 2428 /** Selectors in the list. */ 2429 public final CSS.Value[] selectors; 2430 2431 /** Rule selector text. */ 2432 public final String text; 2433 2434 /** Constructor. Please review this class' fields for documentation. */ 2435 public SelectorList(ReadOnlyList<Boolean> isPresent, Value[] selectors, String text) 2436 { 2437 super(singleton, Domains.CSS, "SelectorList", 2); 2438 2439 this.selectors = selectors; 2440 this.text = text; 2441 2442 this.isPresent = (isPresent == null) 2443 ? singleton.generateIsPresentList(this) 2444 : THROWS.check(isPresent, 2, "CSS.SelectorList"); 2445 } 2446 2447 /** Creates an instance of this class from a {@link JsonObject}.*/ 2448 public static SelectorList fromJSON(JsonObject jo) 2449 { return singleton.fromJSON(jo); } 2450 2451 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 2452 public static NestedDescriptor<SelectorList> descriptor() 2453 { return singleton.descriptor(); } 2454 } 2455 2456 /** 2457 * <CODE>[No Description Provided by Google]</CODE> 2458 * 2459 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 2460 */ 2461 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 2462 public static class ShorthandEntry 2463 extends BaseType<ShorthandEntry> 2464 implements java.io.Serializable 2465 { 2466 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2467 protected static final long serialVersionUID = 1; 2468 2469 private static final NestedHelper<CSS.ShorthandEntry> singleton = 2470 Torello.Browser.BrowserAPI.NestedHelpers.Types. 2471 CSS$$ShorthandEntry$$.singleton; 2472 2473 /** Shorthand name. */ 2474 public final String name; 2475 2476 /** Shorthand value. */ 2477 public final String value; 2478 2479 /** 2480 * Whether the property has "!important" annotation (implies <CODE>false</CODE> if absent). 2481 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2482 */ 2483 public final Boolean important; 2484 2485 /** Constructor. Please review this class' fields for documentation. */ 2486 public ShorthandEntry 2487 (ReadOnlyList<Boolean> isPresent, String name, String value, Boolean important) 2488 { 2489 super(singleton, Domains.CSS, "ShorthandEntry", 3); 2490 2491 this.name = name; 2492 this.value = value; 2493 this.important = important; 2494 2495 this.isPresent = (isPresent == null) 2496 ? singleton.generateIsPresentList(this) 2497 : THROWS.check(isPresent, 3, "CSS.ShorthandEntry"); 2498 } 2499 2500 /** Creates an instance of this class from a {@link JsonObject}.*/ 2501 public static ShorthandEntry fromJSON(JsonObject jo) 2502 { return singleton.fromJSON(jo); } 2503 2504 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 2505 public static NestedDescriptor<ShorthandEntry> descriptor() 2506 { return singleton.descriptor(); } 2507 } 2508 2509 /** 2510 * Text range within a resource. All numbers are zero-based. 2511 * 2512 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 2513 */ 2514 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 2515 public static class SourceRange 2516 extends BaseType<SourceRange> 2517 implements java.io.Serializable 2518 { 2519 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2520 protected static final long serialVersionUID = 1; 2521 2522 private static final NestedHelper<CSS.SourceRange> singleton = 2523 Torello.Browser.BrowserAPI.NestedHelpers.Types. 2524 CSS$$SourceRange$$.singleton; 2525 2526 /** Start line of range. */ 2527 public final int startLine; 2528 2529 /** Start column of range (inclusive). */ 2530 public final int startColumn; 2531 2532 /** End line of range */ 2533 public final int endLine; 2534 2535 /** End column of range (exclusive). */ 2536 public final int endColumn; 2537 2538 /** Constructor. Please review this class' fields for documentation. */ 2539 public SourceRange( 2540 ReadOnlyList<Boolean> isPresent, int startLine, int startColumn, int endLine, 2541 int endColumn 2542 ) 2543 { 2544 super(singleton, Domains.CSS, "SourceRange", 4); 2545 2546 this.startLine = startLine; 2547 this.startColumn = startColumn; 2548 this.endLine = endLine; 2549 this.endColumn = endColumn; 2550 2551 this.isPresent = (isPresent == null) 2552 ? singleton.generateIsPresentList(this) 2553 : THROWS.check(isPresent, 4, "CSS.SourceRange"); 2554 } 2555 2556 /** Creates an instance of this class from a {@link JsonObject}.*/ 2557 public static SourceRange fromJSON(JsonObject jo) 2558 { return singleton.fromJSON(jo); } 2559 2560 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 2561 public static NestedDescriptor<SourceRange> descriptor() 2562 { return singleton.descriptor(); } 2563 } 2564 2565 /** 2566 * Specificity: 2567 * https://drafts.csswg.org/selectors/#specificity-rules 2568 * 2569 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 2570 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 2571 */ 2572 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 2573 public static class Specificity 2574 extends BaseType<Specificity> 2575 implements java.io.Serializable 2576 { 2577 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2578 protected static final long serialVersionUID = 1; 2579 2580 private static final NestedHelper<CSS.Specificity> singleton = 2581 Torello.Browser.BrowserAPI.NestedHelpers.Types. 2582 CSS$$Specificity$$.singleton; 2583 2584 /** The a component, which represents the number of ID selectors. */ 2585 public final int a; 2586 2587 /** 2588 * The b component, which represents the number of class selectors, attributes selectors, and 2589 * pseudo-classes. 2590 */ 2591 public final int b; 2592 2593 /** The c component, which represents the number of type selectors and pseudo-elements. */ 2594 public final int c; 2595 2596 /** Constructor. Please review this class' fields for documentation. */ 2597 public Specificity(ReadOnlyList<Boolean> isPresent, int a, int b, int c) 2598 { 2599 super(singleton, Domains.CSS, "Specificity", 3); 2600 2601 this.a = a; 2602 this.b = b; 2603 this.c = c; 2604 2605 this.isPresent = (isPresent == null) 2606 ? singleton.generateIsPresentList(this) 2607 : THROWS.check(isPresent, 3, "CSS.Specificity"); 2608 } 2609 2610 /** Creates an instance of this class from a {@link JsonObject}.*/ 2611 public static Specificity fromJSON(JsonObject jo) 2612 { return singleton.fromJSON(jo); } 2613 2614 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 2615 public static NestedDescriptor<Specificity> descriptor() 2616 { return singleton.descriptor(); } 2617 } 2618 2619 /** 2620 * A descriptor of operation to mutate style declaration text. 2621 * 2622 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 2623 */ 2624 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 2625 public static class StyleDeclarationEdit 2626 extends BaseType<StyleDeclarationEdit> 2627 implements java.io.Serializable 2628 { 2629 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2630 protected static final long serialVersionUID = 1; 2631 2632 private static final NestedHelper<CSS.StyleDeclarationEdit> singleton = 2633 Torello.Browser.BrowserAPI.NestedHelpers.Types. 2634 CSS$$StyleDeclarationEdit$$.singleton; 2635 2636 /** The css style sheet identifier. */ 2637 public final String styleSheetId; 2638 2639 /** The range of the style text in the enclosing stylesheet. */ 2640 public final CSS.SourceRange range; 2641 2642 /** New style text. */ 2643 public final String text; 2644 2645 /** Constructor. Please review this class' fields for documentation. */ 2646 public StyleDeclarationEdit 2647 (ReadOnlyList<Boolean> isPresent, String styleSheetId, SourceRange range, String text) 2648 { 2649 super(singleton, Domains.CSS, "StyleDeclarationEdit", 3); 2650 2651 this.styleSheetId = styleSheetId; 2652 this.range = range; 2653 this.text = text; 2654 2655 this.isPresent = (isPresent == null) 2656 ? singleton.generateIsPresentList(this) 2657 : THROWS.check(isPresent, 3, "CSS.StyleDeclarationEdit"); 2658 } 2659 2660 /** Creates an instance of this class from a {@link JsonObject}.*/ 2661 public static StyleDeclarationEdit fromJSON(JsonObject jo) 2662 { return singleton.fromJSON(jo); } 2663 2664 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 2665 public static NestedDescriptor<StyleDeclarationEdit> descriptor() 2666 { return singleton.descriptor(); } 2667 } 2668 2669 /** 2670 * Data for a simple selector (these are delimited by commas in a selector list). 2671 * 2672 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 2673 */ 2674 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_TYPE_JDHBI") 2675 public static class Value 2676 extends BaseType<Value> 2677 implements java.io.Serializable 2678 { 2679 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2680 protected static final long serialVersionUID = 1; 2681 2682 private static final NestedHelper<CSS.Value> singleton = 2683 Torello.Browser.BrowserAPI.NestedHelpers.Types. 2684 CSS$$Value$$.singleton; 2685 2686 /** Value text. */ 2687 public final String text; 2688 2689 /** 2690 * Value range in the underlying resource (if available). 2691 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2692 */ 2693 public final CSS.SourceRange range; 2694 2695 /** 2696 * Specificity of the selector. 2697 * <BR /><B CLASS=Opt-Top>OPTIONAL</B><B CLASS=Exp-Top>EXPERIMENTAL</B> 2698 */ 2699 public final CSS.Specificity specificity; 2700 2701 /** Constructor. Please review this class' fields for documentation. */ 2702 public Value( 2703 ReadOnlyList<Boolean> isPresent, String text, SourceRange range, 2704 Specificity specificity 2705 ) 2706 { 2707 super(singleton, Domains.CSS, "Value", 3); 2708 2709 this.text = text; 2710 this.range = range; 2711 this.specificity = specificity; 2712 2713 this.isPresent = (isPresent == null) 2714 ? singleton.generateIsPresentList(this) 2715 : THROWS.check(isPresent, 3, "CSS.Value"); 2716 } 2717 2718 /** Creates an instance of this class from a {@link JsonObject}.*/ 2719 public static Value fromJSON(JsonObject jo) 2720 { return singleton.fromJSON(jo); } 2721 2722 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 2723 public static NestedDescriptor<Value> descriptor() 2724 { return singleton.descriptor(); } 2725 } 2726 2727 2728 // ******************************************************************************************** 2729 // ******************************************************************************************** 2730 // Command-Return Types 2731 // ******************************************************************************************** 2732 // ******************************************************************************************** 2733 2734 2735 /** 2736 * Returns the styles coming from animations & transitions 2737 * including the animation & transition styles coming from inheritance chain. 2738 * 2739 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 2740 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI DATA-CMD=getAnimatedStylesForNode> 2741 * @see CSS#getAnimatedStylesForNode 2742 */ 2743 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_CMD_JDHBI") 2744 public static class getAnimatedStylesForNode$$RET 2745 extends BaseType<getAnimatedStylesForNode$$RET> 2746 implements java.io.Serializable 2747 { 2748 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2749 protected static final long serialVersionUID = 1; 2750 2751 private static final NestedHelper<CSS.getAnimatedStylesForNode$$RET> singleton = 2752 Torello.Browser.BrowserAPI.NestedHelpers.CmdReturns. 2753 CSS$$getAnimatedStylesForNode$$RET.singleton; 2754 2755 /** 2756 * Styles coming from animations. 2757 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2758 */ 2759 public final CSS.CSSAnimationStyle[] animationStyles; 2760 2761 /** 2762 * Style coming from transitions. 2763 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2764 */ 2765 public final CSS.CSSStyle transitionsStyle; 2766 2767 /** 2768 * Inherited style entries for animationsStyle and transitionsStyle from 2769 * the inheritance chain of the element. 2770 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2771 */ 2772 public final CSS.InheritedAnimatedStyleEntry[] inherited; 2773 2774 /** Constructor. Please review this class' fields for documentation. */ 2775 public getAnimatedStylesForNode$$RET( 2776 ReadOnlyList<Boolean> isPresent, CSSAnimationStyle[] animationStyles, 2777 CSSStyle transitionsStyle, InheritedAnimatedStyleEntry[] inherited 2778 ) 2779 { 2780 super(singleton, Domains.CSS, "getAnimatedStylesForNode", 3); 2781 2782 this.animationStyles = animationStyles; 2783 this.transitionsStyle = transitionsStyle; 2784 this.inherited = inherited; 2785 2786 this.isPresent = (isPresent == null) 2787 ? singleton.generateIsPresentList(this) 2788 : THROWS.check(isPresent, 3, "CSS.getAnimatedStylesForNode$$RET"); 2789 } 2790 2791 /** Creates an instance of this class from a {@link JsonObject}.*/ 2792 public static getAnimatedStylesForNode$$RET fromJSON(JsonObject jo) 2793 { return singleton.fromJSON(jo); } 2794 2795 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 2796 public static NestedDescriptor<getAnimatedStylesForNode$$RET> descriptor() 2797 { return singleton.descriptor(); } 2798 } 2799 2800 /** 2801 * <CODE>[No Description Provided by Google]</CODE> 2802 * 2803 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI DATA-CMD=getBackgroundColors> 2804 * @see CSS#getBackgroundColors 2805 */ 2806 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_CMD_JDHBI") 2807 public static class getBackgroundColors$$RET 2808 extends BaseType<getBackgroundColors$$RET> 2809 implements java.io.Serializable 2810 { 2811 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2812 protected static final long serialVersionUID = 1; 2813 2814 private static final NestedHelper<CSS.getBackgroundColors$$RET> singleton = 2815 Torello.Browser.BrowserAPI.NestedHelpers.CmdReturns. 2816 CSS$$getBackgroundColors$$RET.singleton; 2817 2818 /** 2819 * The range of background colors behind this element, if it contains any visible text. If no 2820 * visible text is present, this will be undefined. In the case of a flat background color, 2821 * this will consist of simply that color. In the case of a gradient, this will consist of each 2822 * of the color stops. For anything more complicated, this will be an empty array. Images will 2823 * be ignored (as if the image had failed to load). 2824 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2825 */ 2826 public final String[] backgroundColors; 2827 2828 /** 2829 * The computed font size for this node, as a CSS computed value string (e.g. '12px'). 2830 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2831 */ 2832 public final String computedFontSize; 2833 2834 /** 2835 * The computed font weight for this node, as a CSS computed value string (e.g. 'normal' or 2836 * '100'). 2837 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2838 */ 2839 public final String computedFontWeight; 2840 2841 /** Constructor. Please review this class' fields for documentation. */ 2842 public getBackgroundColors$$RET( 2843 ReadOnlyList<Boolean> isPresent, String[] backgroundColors, 2844 String computedFontSize, String computedFontWeight 2845 ) 2846 { 2847 super(singleton, Domains.CSS, "getBackgroundColors", 3); 2848 2849 this.backgroundColors = backgroundColors; 2850 this.computedFontSize = computedFontSize; 2851 this.computedFontWeight = computedFontWeight; 2852 2853 this.isPresent = (isPresent == null) 2854 ? singleton.generateIsPresentList(this) 2855 : THROWS.check(isPresent, 3, "CSS.getBackgroundColors$$RET"); 2856 } 2857 2858 /** Creates an instance of this class from a {@link JsonObject}.*/ 2859 public static getBackgroundColors$$RET fromJSON(JsonObject jo) 2860 { return singleton.fromJSON(jo); } 2861 2862 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 2863 public static NestedDescriptor<getBackgroundColors$$RET> descriptor() 2864 { return singleton.descriptor(); } 2865 } 2866 2867 /** 2868 * Returns the styles defined inline (explicitly in the "style" attribute and implicitly, using DOM 2869 * attributes) for a DOM node identified by <CODE>nodeId</CODE>. 2870 * 2871 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI DATA-CMD=getInlineStylesForNode> 2872 * @see CSS#getInlineStylesForNode 2873 */ 2874 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_CMD_JDHBI") 2875 public static class getInlineStylesForNode$$RET 2876 extends BaseType<getInlineStylesForNode$$RET> 2877 implements java.io.Serializable 2878 { 2879 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2880 protected static final long serialVersionUID = 1; 2881 2882 private static final NestedHelper<CSS.getInlineStylesForNode$$RET> singleton = 2883 Torello.Browser.BrowserAPI.NestedHelpers.CmdReturns. 2884 CSS$$getInlineStylesForNode$$RET.singleton; 2885 2886 /** 2887 * Inline style for the specified DOM node. 2888 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2889 */ 2890 public final CSS.CSSStyle inlineStyle; 2891 2892 /** 2893 * Attribute-defined element style (e.g. resulting from "width=20 height=100%"). 2894 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2895 */ 2896 public final CSS.CSSStyle attributesStyle; 2897 2898 /** Constructor. Please review this class' fields for documentation. */ 2899 public getInlineStylesForNode$$RET 2900 (ReadOnlyList<Boolean> isPresent, CSSStyle inlineStyle, CSSStyle attributesStyle) 2901 { 2902 super(singleton, Domains.CSS, "getInlineStylesForNode", 2); 2903 2904 this.inlineStyle = inlineStyle; 2905 this.attributesStyle = attributesStyle; 2906 2907 this.isPresent = (isPresent == null) 2908 ? singleton.generateIsPresentList(this) 2909 : THROWS.check(isPresent, 2, "CSS.getInlineStylesForNode$$RET"); 2910 } 2911 2912 /** Creates an instance of this class from a {@link JsonObject}.*/ 2913 public static getInlineStylesForNode$$RET fromJSON(JsonObject jo) 2914 { return singleton.fromJSON(jo); } 2915 2916 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 2917 public static NestedDescriptor<getInlineStylesForNode$$RET> descriptor() 2918 { return singleton.descriptor(); } 2919 } 2920 2921 /** 2922 * Returns requested styles for a DOM node identified by <CODE>nodeId</CODE>. 2923 * 2924 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI DATA-CMD=getMatchedStylesForNode> 2925 * @see CSS#getMatchedStylesForNode 2926 */ 2927 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_CMD_JDHBI") 2928 public static class getMatchedStylesForNode$$RET 2929 extends BaseType<getMatchedStylesForNode$$RET> 2930 implements java.io.Serializable 2931 { 2932 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 2933 protected static final long serialVersionUID = 1; 2934 2935 private static final NestedHelper<CSS.getMatchedStylesForNode$$RET> singleton = 2936 Torello.Browser.BrowserAPI.NestedHelpers.CmdReturns. 2937 CSS$$getMatchedStylesForNode$$RET.singleton; 2938 2939 /** 2940 * Inline style for the specified DOM node. 2941 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2942 */ 2943 public final CSS.CSSStyle inlineStyle; 2944 2945 /** 2946 * Attribute-defined element style (e.g. resulting from "width=20 height=100%"). 2947 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2948 */ 2949 public final CSS.CSSStyle attributesStyle; 2950 2951 /** 2952 * CSS rules matching this node, from all applicable stylesheets. 2953 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2954 */ 2955 public final CSS.RuleMatch[] matchedCSSRules; 2956 2957 /** 2958 * Pseudo style matches for this node. 2959 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2960 */ 2961 public final CSS.PseudoElementMatches[] pseudoElements; 2962 2963 /** 2964 * A chain of inherited styles (from the immediate node parent up to the DOM tree root). 2965 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2966 */ 2967 public final CSS.InheritedStyleEntry[] inherited; 2968 2969 /** 2970 * A chain of inherited pseudo element styles (from the immediate node parent up to the DOM tree root). 2971 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2972 */ 2973 public final CSS.InheritedPseudoElementMatches[] inheritedPseudoElements; 2974 2975 /** 2976 * A list of CSS keyframed animations matching this node. 2977 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2978 */ 2979 public final CSS.CSSKeyframesRule[] cssKeyframesRules; 2980 2981 /** 2982 * A list of CSS @position-try rules matching this node, based on the position-try-fallbacks property. 2983 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2984 */ 2985 public final CSS.CSSPositionTryRule[] cssPositionTryRules; 2986 2987 /** 2988 * Index of the active fallback in the applied position-try-fallback property, 2989 * will not be set if there is no active position-try fallback. 2990 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2991 */ 2992 public final Integer activePositionFallbackIndex; 2993 2994 /** 2995 * A list of CSS at-property rules matching this node. 2996 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 2997 */ 2998 public final CSS.CSSPropertyRule[] cssPropertyRules; 2999 3000 /** 3001 * A list of CSS property registrations matching this node. 3002 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 3003 */ 3004 public final CSS.CSSPropertyRegistration[] cssPropertyRegistrations; 3005 3006 /** 3007 * A font-palette-values rule matching this node. 3008 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 3009 */ 3010 public final CSS.CSSFontPaletteValuesRule cssFontPaletteValuesRule; 3011 3012 /** 3013 * Id of the first parent element that does not have display: contents. 3014 * <BR /><B CLASS=Opt-Top>OPTIONAL</B><B CLASS=Exp-Top>EXPERIMENTAL</B> 3015 */ 3016 public final Integer parentLayoutNodeId; 3017 3018 /** 3019 * A list of CSS at-function rules referenced by styles of this node. 3020 * <BR /><B CLASS=Opt-Top>OPTIONAL</B><B CLASS=Exp-Top>EXPERIMENTAL</B> 3021 */ 3022 public final CSS.CSSFunctionRule[] cssFunctionRules; 3023 3024 /** Constructor. Please review this class' fields for documentation. */ 3025 public getMatchedStylesForNode$$RET( 3026 ReadOnlyList<Boolean> isPresent, CSSStyle inlineStyle, CSSStyle attributesStyle, 3027 RuleMatch[] matchedCSSRules, PseudoElementMatches[] pseudoElements, 3028 InheritedStyleEntry[] inherited, 3029 InheritedPseudoElementMatches[] inheritedPseudoElements, 3030 CSSKeyframesRule[] cssKeyframesRules, CSSPositionTryRule[] cssPositionTryRules, 3031 Integer activePositionFallbackIndex, CSSPropertyRule[] cssPropertyRules, 3032 CSSPropertyRegistration[] cssPropertyRegistrations, 3033 CSSFontPaletteValuesRule cssFontPaletteValuesRule, Integer parentLayoutNodeId, 3034 CSSFunctionRule[] cssFunctionRules 3035 ) 3036 { 3037 super(singleton, Domains.CSS, "getMatchedStylesForNode", 14); 3038 3039 this.inlineStyle = inlineStyle; 3040 this.attributesStyle = attributesStyle; 3041 this.matchedCSSRules = matchedCSSRules; 3042 this.pseudoElements = pseudoElements; 3043 this.inherited = inherited; 3044 this.inheritedPseudoElements = inheritedPseudoElements; 3045 this.cssKeyframesRules = cssKeyframesRules; 3046 this.cssPositionTryRules = cssPositionTryRules; 3047 this.activePositionFallbackIndex = activePositionFallbackIndex; 3048 this.cssPropertyRules = cssPropertyRules; 3049 this.cssPropertyRegistrations = cssPropertyRegistrations; 3050 this.cssFontPaletteValuesRule = cssFontPaletteValuesRule; 3051 this.parentLayoutNodeId = parentLayoutNodeId; 3052 this.cssFunctionRules = cssFunctionRules; 3053 3054 this.isPresent = (isPresent == null) 3055 ? singleton.generateIsPresentList(this) 3056 : THROWS.check(isPresent, 14, "CSS.getMatchedStylesForNode$$RET"); 3057 } 3058 3059 /** Creates an instance of this class from a {@link JsonObject}.*/ 3060 public static getMatchedStylesForNode$$RET fromJSON(JsonObject jo) 3061 { return singleton.fromJSON(jo); } 3062 3063 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 3064 public static NestedDescriptor<getMatchedStylesForNode$$RET> descriptor() 3065 { return singleton.descriptor(); } 3066 } 3067 3068 /** 3069 * Obtain list of rules that became used since last call to this method (or since start of coverage 3070 * instrumentation). 3071 * 3072 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI DATA-CMD=takeCoverageDelta> 3073 * @see CSS#takeCoverageDelta 3074 */ 3075 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_CMD_JDHBI") 3076 public static class takeCoverageDelta$$RET 3077 extends BaseType<takeCoverageDelta$$RET> 3078 implements java.io.Serializable 3079 { 3080 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 3081 protected static final long serialVersionUID = 1; 3082 3083 private static final NestedHelper<CSS.takeCoverageDelta$$RET> singleton = 3084 Torello.Browser.BrowserAPI.NestedHelpers.CmdReturns. 3085 CSS$$takeCoverageDelta$$RET.singleton; 3086 3087 /** <CODE>[No Description Provided by Google]</CODE> */ 3088 public final CSS.RuleUsage[] coverage; 3089 3090 /** Monotonically increasing time, in seconds. */ 3091 public final Number timestamp; 3092 3093 /** Constructor. Please review this class' fields for documentation. */ 3094 public takeCoverageDelta$$RET 3095 (ReadOnlyList<Boolean> isPresent, RuleUsage[] coverage, Number timestamp) 3096 { 3097 super(singleton, Domains.CSS, "takeCoverageDelta", 2); 3098 3099 this.coverage = coverage; 3100 this.timestamp = timestamp; 3101 3102 this.isPresent = (isPresent == null) 3103 ? singleton.generateIsPresentList(this) 3104 : THROWS.check(isPresent, 2, "CSS.takeCoverageDelta$$RET"); 3105 } 3106 3107 /** Creates an instance of this class from a {@link JsonObject}.*/ 3108 public static takeCoverageDelta$$RET fromJSON(JsonObject jo) 3109 { return singleton.fromJSON(jo); } 3110 3111 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 3112 public static NestedDescriptor<takeCoverageDelta$$RET> descriptor() 3113 { return singleton.descriptor(); } 3114 } 3115 3116 3117 // ******************************************************************************************** 3118 // ******************************************************************************************** 3119 // Event Types 3120 // ******************************************************************************************** 3121 // ******************************************************************************************** 3122 3123 3124 /** 3125 * <CODE>[No Description Provided by Google]</CODE> 3126 * 3127 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 3128 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 3129 */ 3130 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_EVENT_JDHBI") 3131 public static class computedStyleUpdated 3132 extends BrowserEvent<computedStyleUpdated> 3133 implements java.io.Serializable 3134 { 3135 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 3136 protected static final long serialVersionUID = 1; 3137 3138 private static final NestedHelper<CSS.computedStyleUpdated> singleton = 3139 Torello.Browser.BrowserAPI.NestedHelpers.Events. 3140 CSS$$computedStyleUpdated$$.singleton; 3141 3142 /** The node id that has updated computed styles. */ 3143 public final int nodeId; 3144 3145 /** Constructor. Please review this class' fields for documentation. */ 3146 public computedStyleUpdated(ReadOnlyList<Boolean> isPresent, int nodeId) 3147 { 3148 super(singleton, Domains.CSS, "computedStyleUpdated", 1); 3149 3150 this.nodeId = nodeId; 3151 3152 this.isPresent = (isPresent == null) 3153 ? singleton.generateIsPresentList(this) 3154 : THROWS.check(isPresent, 1, "CSS.computedStyleUpdated"); 3155 } 3156 3157 /** Creates an instance of this class from a {@link JsonObject}.*/ 3158 public static computedStyleUpdated fromJSON(JsonObject jo) 3159 { return singleton.fromJSON(jo); } 3160 3161 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 3162 public static NestedDescriptor<computedStyleUpdated> descriptor() 3163 { return singleton.descriptor(); } 3164 } 3165 3166 /** 3167 * Fires whenever a web font is updated. A non-empty font parameter indicates a successfully loaded 3168 * web font. 3169 * 3170 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 3171 */ 3172 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_EVENT_JDHBI") 3173 public static class fontsUpdated 3174 extends BrowserEvent<fontsUpdated> 3175 implements java.io.Serializable 3176 { 3177 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 3178 protected static final long serialVersionUID = 1; 3179 3180 private static final NestedHelper<CSS.fontsUpdated> singleton = 3181 Torello.Browser.BrowserAPI.NestedHelpers.Events. 3182 CSS$$fontsUpdated$$.singleton; 3183 3184 /** 3185 * The web font that has loaded. 3186 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 3187 */ 3188 public final CSS.FontFace font; 3189 3190 /** Constructor. Please review this class' fields for documentation. */ 3191 public fontsUpdated(ReadOnlyList<Boolean> isPresent, FontFace font) 3192 { 3193 super(singleton, Domains.CSS, "fontsUpdated", 1); 3194 3195 this.font = font; 3196 3197 this.isPresent = (isPresent == null) 3198 ? singleton.generateIsPresentList(this) 3199 : THROWS.check(isPresent, 1, "CSS.fontsUpdated"); 3200 } 3201 3202 /** Creates an instance of this class from a {@link JsonObject}.*/ 3203 public static fontsUpdated fromJSON(JsonObject jo) 3204 { return singleton.fromJSON(jo); } 3205 3206 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 3207 public static NestedDescriptor<fontsUpdated> descriptor() 3208 { return singleton.descriptor(); } 3209 } 3210 3211 /** 3212 * Fired whenever an active document stylesheet is added. 3213 * 3214 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 3215 */ 3216 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_EVENT_JDHBI") 3217 public static class styleSheetAdded 3218 extends BrowserEvent<styleSheetAdded> 3219 implements java.io.Serializable 3220 { 3221 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 3222 protected static final long serialVersionUID = 1; 3223 3224 private static final NestedHelper<CSS.styleSheetAdded> singleton = 3225 Torello.Browser.BrowserAPI.NestedHelpers.Events. 3226 CSS$$styleSheetAdded$$.singleton; 3227 3228 /** Added stylesheet metainfo. */ 3229 public final CSS.CSSStyleSheetHeader header; 3230 3231 /** Constructor. Please review this class' fields for documentation. */ 3232 public styleSheetAdded(ReadOnlyList<Boolean> isPresent, CSSStyleSheetHeader header) 3233 { 3234 super(singleton, Domains.CSS, "styleSheetAdded", 1); 3235 3236 this.header = header; 3237 3238 this.isPresent = (isPresent == null) 3239 ? singleton.generateIsPresentList(this) 3240 : THROWS.check(isPresent, 1, "CSS.styleSheetAdded"); 3241 } 3242 3243 /** Creates an instance of this class from a {@link JsonObject}.*/ 3244 public static styleSheetAdded fromJSON(JsonObject jo) 3245 { return singleton.fromJSON(jo); } 3246 3247 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 3248 public static NestedDescriptor<styleSheetAdded> descriptor() 3249 { return singleton.descriptor(); } 3250 } 3251 3252 /** 3253 * Fired whenever a stylesheet is changed as a result of the client operation. 3254 * 3255 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 3256 */ 3257 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_EVENT_JDHBI") 3258 public static class styleSheetChanged 3259 extends BrowserEvent<styleSheetChanged> 3260 implements java.io.Serializable 3261 { 3262 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 3263 protected static final long serialVersionUID = 1; 3264 3265 private static final NestedHelper<CSS.styleSheetChanged> singleton = 3266 Torello.Browser.BrowserAPI.NestedHelpers.Events. 3267 CSS$$styleSheetChanged$$.singleton; 3268 3269 /** <CODE>[No Description Provided by Google]</CODE> */ 3270 public final String styleSheetId; 3271 3272 /** Constructor. Please review this class' fields for documentation. */ 3273 public styleSheetChanged(ReadOnlyList<Boolean> isPresent, String styleSheetId) 3274 { 3275 super(singleton, Domains.CSS, "styleSheetChanged", 1); 3276 3277 this.styleSheetId = styleSheetId; 3278 3279 this.isPresent = (isPresent == null) 3280 ? singleton.generateIsPresentList(this) 3281 : THROWS.check(isPresent, 1, "CSS.styleSheetChanged"); 3282 } 3283 3284 /** Creates an instance of this class from a {@link JsonObject}.*/ 3285 public static styleSheetChanged fromJSON(JsonObject jo) 3286 { return singleton.fromJSON(jo); } 3287 3288 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 3289 public static NestedDescriptor<styleSheetChanged> descriptor() 3290 { return singleton.descriptor(); } 3291 } 3292 3293 /** 3294 * Fired whenever an active document stylesheet is removed. 3295 * 3296 * <EMBED CLASS=globalDefs DATA-DOMAIN=CSS DATA-API=BrowserAPI> 3297 */ 3298 @JDHeaderBackgroundImg(EmbedTagFileID="CDP.NESTED_EVENT_JDHBI") 3299 public static class styleSheetRemoved 3300 extends BrowserEvent<styleSheetRemoved> 3301 implements java.io.Serializable 3302 { 3303 /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUID> */ 3304 protected static final long serialVersionUID = 1; 3305 3306 private static final NestedHelper<CSS.styleSheetRemoved> singleton = 3307 Torello.Browser.BrowserAPI.NestedHelpers.Events. 3308 CSS$$styleSheetRemoved$$.singleton; 3309 3310 /** Identifier of the removed stylesheet. */ 3311 public final String styleSheetId; 3312 3313 /** Constructor. Please review this class' fields for documentation. */ 3314 public styleSheetRemoved(ReadOnlyList<Boolean> isPresent, String styleSheetId) 3315 { 3316 super(singleton, Domains.CSS, "styleSheetRemoved", 1); 3317 3318 this.styleSheetId = styleSheetId; 3319 3320 this.isPresent = (isPresent == null) 3321 ? singleton.generateIsPresentList(this) 3322 : THROWS.check(isPresent, 1, "CSS.styleSheetRemoved"); 3323 } 3324 3325 /** Creates an instance of this class from a {@link JsonObject}.*/ 3326 public static styleSheetRemoved fromJSON(JsonObject jo) 3327 { return singleton.fromJSON(jo); } 3328 3329 /** Returns this class's {@link NestedDescriptor} singleton-instance. class / type.*/ 3330 public static NestedDescriptor<styleSheetRemoved> descriptor() 3331 { return singleton.descriptor(); } 3332 } 3333 3334 3335 3336 3337 // ******************************************************************************************** 3338 // ******************************************************************************************** 3339 // Commands 3340 // ******************************************************************************************** 3341 // ******************************************************************************************** 3342 3343 3344 /** 3345 * Inserts a new rule with the given <CODE>ruleText</CODE> in a stylesheet with given <CODE>styleSheetId</CODE>, at the 3346 * position specified by <CODE>location</CODE>. 3347 * 3348 * @param styleSheetId The css style sheet identifier where a new rule should be inserted. 3349 * 3350 * @param ruleText The text of a new rule. 3351 * 3352 * @param location Text position of a new rule in the target style sheet. 3353 * 3354 * @param nodeForPropertySyntaxValidation 3355 * NodeId for the DOM node in whose context custom property declarations for registered properties should be 3356 * validated. If omitted, declarations in the new rule text can only be validated statically, which may produce 3357 * incorrect results if the declaration contains a var() for example. 3358 * <BR /><B CLASS=Opt-Top>OPTIONAL</B><B CLASS=Exp-Top>EXPERIMENTAL</B> 3359 * 3360 * @return An instance of <CODE>{@link Script}<{@link CSS.CSSRule}></CODE> 3361 * 3362 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 3363 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 3364 * <CODE><{@link CSS.CSSRule}></CODE> will be returned 3365 * 3366 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 3367 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 3368 * be retrieved.</I> 3369 * 3370 * <BR /><BR /><DIV CLASS=JDHint> 3371 * This Browser Function's {@code Promise} returns: 3372 * <CODE>{@link CSS.CSSRule} (<B>rule</B>)</CODE> 3373 * <BR /> 3374 * The newly created rule. 3375 * </DIV> 3376 */ 3377 public static Script<CSS.CSSRule> addRule( 3378 String styleSheetId, String ruleText, SourceRange location, 3379 Integer nodeForPropertySyntaxValidation 3380 ) 3381 { 3382 // Convert all Method Parameters into a JSON Request-Object (as a String) 3383 final String requestJSON = WriteJSON.get( 3384 CSS$$Commands.addRule$$, "CSS.addRule", 3385 styleSheetId, ruleText, location, nodeForPropertySyntaxValidation 3386 ); 3387 3388 return new Script<>( 3389 Domains.CSS, "addRule", requestJSON, 3390 CSS$$Commands::addRule, 3391 CSS.CSSRule.class 3392 ); 3393 } 3394 3395 /** 3396 * Returns all class names from specified stylesheet. 3397 * 3398 * @param styleSheetId - 3399 * 3400 * @return An instance of <CODE>{@link Script}<String[]></CODE> 3401 * 3402 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 3403 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 3404 * <CODE><String[]></CODE> will be returned 3405 * 3406 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 3407 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 3408 * be retrieved.</I> 3409 * 3410 * <BR /><BR /><DIV CLASS=JDHint> 3411 * This Browser Function's {@code Promise} returns: 3412 * <CODE>String[] (<B>classNames</B>)</CODE> 3413 * <BR /> 3414 * Class name list. 3415 * </DIV> 3416 */ 3417 public static Script<String[]> collectClassNames(String styleSheetId) 3418 { 3419 // Build the JSON Request-Object (as a String); only 1 Parameter is passed 3420 final String requestJSON = WriteJSON.get 3421 (CDPTypes.STRING, "styleSheetId", false, "CSS.collectClassNames", styleSheetId); 3422 3423 return new Script<>( 3424 Domains.CSS, "collectClassNames", requestJSON, 3425 CSS$$Commands::collectClassNames, 3426 String[].class 3427 ); 3428 } 3429 3430 /** 3431 * Creates a new special "via-inspector" stylesheet in the frame with given <CODE>frameId</CODE>. 3432 * 3433 * @param frameId Identifier of the frame where "via-inspector" stylesheet should be created. 3434 * 3435 * @param force 3436 * If true, creates a new stylesheet for every call. If false, 3437 * returns a stylesheet previously created by a call with force=false 3438 * for the frame's document if it exists or creates a new stylesheet 3439 * (default: false). 3440 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 3441 * 3442 * @return An instance of <CODE>{@link Script}<String></CODE> 3443 * 3444 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 3445 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 3446 * <CODE><String></CODE> will be returned 3447 * 3448 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 3449 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 3450 * be retrieved.</I> 3451 * 3452 * <BR /><BR /><DIV CLASS=JDHint> 3453 * This Browser Function's {@code Promise} returns: 3454 * <CODE>String (<B>styleSheetId</B>)</CODE> 3455 * <BR /> 3456 * Identifier of the created "via-inspector" stylesheet. 3457 * </DIV> 3458 */ 3459 public static Script<String> createStyleSheet(String frameId, Boolean force) 3460 { 3461 // Convert all Method Parameters into a JSON Request-Object (as a String) 3462 final String requestJSON = WriteJSON.get( 3463 CSS$$Commands.createStyleSheet$$, "CSS.createStyleSheet", 3464 frameId, force 3465 ); 3466 3467 return new Script<>( 3468 Domains.CSS, "createStyleSheet", requestJSON, 3469 jo -> ReadJSON.getString(jo, "styleSheetId", true, false), 3470 String.class 3471 ); 3472 } 3473 3474 /** 3475 * Disables the CSS agent for the given page. 3476 * 3477 * @return An instance of <CODE>{@link Script}<Void></CODE> 3478 * 3479 * <BR /><BR />This {@code Script} instance must be <B STYLE='color:red'>executed</B> before the 3480 * browser receives the invocation-request. 3481 * 3482 * <BR /><BR /><DIV CLASS=JDHint> 3483 * This Browser-Function <I>does not have</I> a return-value. You may choose to 3484 * <B STYLE='color: red'>await</B> the {@link Promise}{@code <Void>} to ensure that 3485 * the Browser Function has run to completion. 3486 * </DIV> 3487 */ 3488 public static Script<Void> disable() 3489 { 3490 // Ultra-Simple Request JSON - Because this method has no parameters 3491 final String requestJSON = "{\"method\":\"CSS.disable\"}"; 3492 3493 return Script.NO_RET(Domains.CSS, "disable", requestJSON); 3494 } 3495 3496 /** 3497 * Enables the CSS agent for the given page. Clients should not assume that the CSS agent has been 3498 * enabled until the result of this command is received. 3499 * 3500 * @return An instance of <CODE>{@link Script}<Void></CODE> 3501 * 3502 * <BR /><BR />This {@code Script} instance must be <B STYLE='color:red'>executed</B> before the 3503 * browser receives the invocation-request. 3504 * 3505 * <BR /><BR /><DIV CLASS=JDHint> 3506 * This Browser-Function <I>does not have</I> a return-value. You may choose to 3507 * <B STYLE='color: red'>await</B> the {@link Promise}{@code <Void>} to ensure that 3508 * the Browser Function has run to completion. 3509 * </DIV> 3510 */ 3511 public static Script<Void> enable() 3512 { 3513 // Ultra-Simple Request JSON - Because this method has no parameters 3514 final String requestJSON = "{\"method\":\"CSS.enable\"}"; 3515 3516 return Script.NO_RET(Domains.CSS, "enable", requestJSON); 3517 } 3518 3519 /** 3520 * Ensures that the given node will have specified pseudo-classes whenever its style is computed by 3521 * the browser. 3522 * 3523 * @param nodeId The element id for which to force the pseudo state. 3524 * 3525 * @param forcedPseudoClasses Element pseudo classes to force when computing the element's style. 3526 * 3527 * @return An instance of <CODE>{@link Script}<Void></CODE> 3528 * 3529 * <BR /><BR />This {@code Script} instance must be <B STYLE='color:red'>executed</B> before the 3530 * browser receives the invocation-request. 3531 * 3532 * <BR /><BR /><DIV CLASS=JDHint> 3533 * This Browser-Function <I>does not have</I> a return-value. You may choose to 3534 * <B STYLE='color: red'>await</B> the {@link Promise}{@code <Void>} to ensure that 3535 * the Browser Function has run to completion. 3536 * </DIV> 3537 */ 3538 public static Script<Void> forcePseudoState(int nodeId, String[] forcedPseudoClasses) 3539 { 3540 // Convert all Method Parameters into a JSON Request-Object (as a String) 3541 final String requestJSON = WriteJSON.get( 3542 CSS$$Commands.forcePseudoState$$, "CSS.forcePseudoState", 3543 nodeId, forcedPseudoClasses 3544 ); 3545 3546 return Script.NO_RET(Domains.CSS, "forcePseudoState", requestJSON); 3547 } 3548 3549 /** 3550 * Ensures that the given node is in its starting-style state. 3551 * 3552 * @param nodeId The element id for which to force the starting-style state. 3553 * 3554 * @param forced Boolean indicating if this is on or off. 3555 * 3556 * @return An instance of <CODE>{@link Script}<Void></CODE> 3557 * 3558 * <BR /><BR />This {@code Script} instance must be <B STYLE='color:red'>executed</B> before the 3559 * browser receives the invocation-request. 3560 * 3561 * <BR /><BR /><DIV CLASS=JDHint> 3562 * This Browser-Function <I>does not have</I> a return-value. You may choose to 3563 * <B STYLE='color: red'>await</B> the {@link Promise}{@code <Void>} to ensure that 3564 * the Browser Function has run to completion. 3565 * </DIV> 3566 */ 3567 public static Script<Void> forceStartingStyle(int nodeId, boolean forced) 3568 { 3569 // Convert all Method Parameters into a JSON Request-Object (as a String) 3570 final String requestJSON = WriteJSON.get( 3571 CSS$$Commands.forceStartingStyle$$, "CSS.forceStartingStyle", 3572 nodeId, forced 3573 ); 3574 3575 return Script.NO_RET(Domains.CSS, "forceStartingStyle", requestJSON); 3576 } 3577 3578 /** 3579 * Returns the styles coming from animations & transitions 3580 * including the animation & transition styles coming from inheritance chain. 3581 * 3582 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 3583 * 3584 * @param nodeId - 3585 * 3586 * @return An instance of <CODE>{@link Script}<{@link getAnimatedStylesForNode$$RET}></CODE> 3587 * 3588 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 3589 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 3590 * <CODE><{@link getAnimatedStylesForNode$$RET}></CODE> will be returned 3591 * 3592 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 3593 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 3594 * be retrieved.</I> 3595 * 3596 * <BR /><BR /><DIV CLASS=JDHint> 3597 * This Browser Function's {@code Promise} returns:{@link getAnimatedStylesForNode$$RET} 3598 * A dedicated return type implies that the browser may return more than 1 datum 3599 * </DIV> 3600 */ 3601 public static Script<getAnimatedStylesForNode$$RET> getAnimatedStylesForNode(int nodeId) 3602 { 3603 // Build the JSON Request-Object (as a String); only 1 Parameter is passed 3604 final String requestJSON = WriteJSON.get 3605 (CDPTypes.PRIMITIVE_INT, "nodeId", false, "CSS.getAnimatedStylesForNode", nodeId); 3606 3607 return new Script<>( 3608 Domains.CSS, "getAnimatedStylesForNode", requestJSON, 3609 getAnimatedStylesForNode$$RET::fromJSON, 3610 getAnimatedStylesForNode$$RET.class 3611 ); 3612 } 3613 3614 /** 3615 * <CODE>[No Description Provided by Google]</CODE> 3616 * 3617 * @param nodeId Id of the node to get background colors for. 3618 * 3619 * @return An instance of <CODE>{@link Script}<{@link getBackgroundColors$$RET}></CODE> 3620 * 3621 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 3622 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 3623 * <CODE><{@link getBackgroundColors$$RET}></CODE> will be returned 3624 * 3625 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 3626 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 3627 * be retrieved.</I> 3628 * 3629 * <BR /><BR /><DIV CLASS=JDHint> 3630 * This Browser Function's {@code Promise} returns:{@link getBackgroundColors$$RET} 3631 * A dedicated return type implies that the browser may return more than 1 datum 3632 * </DIV> 3633 */ 3634 public static Script<getBackgroundColors$$RET> getBackgroundColors(int nodeId) 3635 { 3636 // Build the JSON Request-Object (as a String); only 1 Parameter is passed 3637 final String requestJSON = WriteJSON.get 3638 (CDPTypes.PRIMITIVE_INT, "nodeId", false, "CSS.getBackgroundColors", nodeId); 3639 3640 return new Script<>( 3641 Domains.CSS, "getBackgroundColors", requestJSON, 3642 getBackgroundColors$$RET::fromJSON, 3643 getBackgroundColors$$RET.class 3644 ); 3645 } 3646 3647 /** 3648 * Returns the computed style for a DOM node identified by <CODE>nodeId</CODE>. 3649 * 3650 * @param nodeId - 3651 * 3652 * @return An instance of <CODE>{@link Script}<{@link CSS.CSSComputedStyleProperty}[]></CODE> 3653 * 3654 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 3655 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 3656 * <CODE><{@link CSS.CSSComputedStyleProperty}[]></CODE> will be returned 3657 * 3658 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 3659 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 3660 * be retrieved.</I> 3661 * 3662 * <BR /><BR /><DIV CLASS=JDHint> 3663 * This Browser Function's {@code Promise} returns: 3664 * <CODE>{@link CSS.CSSComputedStyleProperty}[] (<B>computedStyle</B>)</CODE> 3665 * <BR /> 3666 * Computed style for the specified DOM node. 3667 * </DIV> 3668 */ 3669 public static Script<CSS.CSSComputedStyleProperty[]> getComputedStyleForNode(int nodeId) 3670 { 3671 // Build the JSON Request-Object (as a String); only 1 Parameter is passed 3672 final String requestJSON = WriteJSON.get 3673 (CDPTypes.PRIMITIVE_INT, "nodeId", false, "CSS.getComputedStyleForNode", nodeId); 3674 3675 return new Script<>( 3676 Domains.CSS, "getComputedStyleForNode", requestJSON, 3677 CSS$$Commands::getComputedStyleForNode, 3678 CSS.CSSComputedStyleProperty[].class 3679 ); 3680 } 3681 3682 /** 3683 * Returns the values of the default UA-defined environment variables used in env() 3684 * 3685 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 3686 * 3687 * @return An instance of <CODE>{@link Script}<JsonValue></CODE> 3688 * 3689 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 3690 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 3691 * <CODE><JsonValue></CODE> will be returned 3692 * 3693 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 3694 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 3695 * be retrieved.</I> 3696 * 3697 * <BR /><BR /><DIV CLASS=JDHint> 3698 * This Browser Function's {@code Promise} returns: 3699 * <CODE>JsonValue (<B>environmentVariables</B>)</CODE> 3700 * </DIV> 3701 */ 3702 public static Script<JsonValue> getEnvironmentVariables() 3703 { 3704 // Ultra-Simple Request JSON - Because this method has no parameters 3705 final String requestJSON = "{\"method\":\"CSS.getEnvironmentVariables\"}"; 3706 3707 return new Script<>( 3708 Domains.CSS, "getEnvironmentVariables", requestJSON, 3709 jo -> jo.get("environmentVariables"), 3710 JsonValue.class 3711 ); 3712 } 3713 3714 /** 3715 * Returns the styles defined inline (explicitly in the "style" attribute and implicitly, using DOM 3716 * attributes) for a DOM node identified by <CODE>nodeId</CODE>. 3717 * 3718 * @param nodeId - 3719 * 3720 * @return An instance of <CODE>{@link Script}<{@link getInlineStylesForNode$$RET}></CODE> 3721 * 3722 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 3723 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 3724 * <CODE><{@link getInlineStylesForNode$$RET}></CODE> will be returned 3725 * 3726 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 3727 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 3728 * be retrieved.</I> 3729 * 3730 * <BR /><BR /><DIV CLASS=JDHint> 3731 * This Browser Function's {@code Promise} returns:{@link getInlineStylesForNode$$RET} 3732 * A dedicated return type implies that the browser may return more than 1 datum 3733 * </DIV> 3734 */ 3735 public static Script<getInlineStylesForNode$$RET> getInlineStylesForNode(int nodeId) 3736 { 3737 // Build the JSON Request-Object (as a String); only 1 Parameter is passed 3738 final String requestJSON = WriteJSON.get 3739 (CDPTypes.PRIMITIVE_INT, "nodeId", false, "CSS.getInlineStylesForNode", nodeId); 3740 3741 return new Script<>( 3742 Domains.CSS, "getInlineStylesForNode", requestJSON, 3743 getInlineStylesForNode$$RET::fromJSON, 3744 getInlineStylesForNode$$RET.class 3745 ); 3746 } 3747 3748 /** 3749 * Returns all layers parsed by the rendering engine for the tree scope of a node. 3750 * Given a DOM element identified by nodeId, getLayersForNode returns the root 3751 * layer for the nearest ancestor document or shadow root. The layer root contains 3752 * the full layer tree for the tree scope and their ordering. 3753 * 3754 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 3755 * 3756 * @param nodeId - 3757 * 3758 * @return An instance of <CODE>{@link Script}<{@link CSS.CSSLayerData}></CODE> 3759 * 3760 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 3761 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 3762 * <CODE><{@link CSS.CSSLayerData}></CODE> will be returned 3763 * 3764 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 3765 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 3766 * be retrieved.</I> 3767 * 3768 * <BR /><BR /><DIV CLASS=JDHint> 3769 * This Browser Function's {@code Promise} returns: 3770 * <CODE>{@link CSS.CSSLayerData} (<B>rootLayer</B>)</CODE> 3771 * </DIV> 3772 */ 3773 public static Script<CSS.CSSLayerData> getLayersForNode(int nodeId) 3774 { 3775 // Build the JSON Request-Object (as a String); only 1 Parameter is passed 3776 final String requestJSON = WriteJSON.get 3777 (CDPTypes.PRIMITIVE_INT, "nodeId", false, "CSS.getLayersForNode", nodeId); 3778 3779 return new Script<>( 3780 Domains.CSS, "getLayersForNode", requestJSON, 3781 CSS$$Commands::getLayersForNode, 3782 CSS.CSSLayerData.class 3783 ); 3784 } 3785 3786 /** 3787 * Given a CSS selector text and a style sheet ID, getLocationForSelector 3788 * returns an array of locations of the CSS selector in the style sheet. 3789 * 3790 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 3791 * 3792 * @param styleSheetId - 3793 * 3794 * @param selectorText - 3795 * 3796 * @return An instance of <CODE>{@link Script}<{@link CSS.SourceRange}[]></CODE> 3797 * 3798 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 3799 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 3800 * <CODE><{@link CSS.SourceRange}[]></CODE> will be returned 3801 * 3802 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 3803 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 3804 * be retrieved.</I> 3805 * 3806 * <BR /><BR /><DIV CLASS=JDHint> 3807 * This Browser Function's {@code Promise} returns: 3808 * <CODE>{@link CSS.SourceRange}[] (<B>ranges</B>)</CODE> 3809 * </DIV> 3810 */ 3811 public static Script<CSS.SourceRange[]> getLocationForSelector 3812 (String styleSheetId, String selectorText) 3813 { 3814 // Convert all Method Parameters into a JSON Request-Object (as a String) 3815 final String requestJSON = WriteJSON.get( 3816 CSS$$Commands.getLocationForSelector$$, "CSS.getLocationForSelector", 3817 styleSheetId, selectorText 3818 ); 3819 3820 return new Script<>( 3821 Domains.CSS, "getLocationForSelector", requestJSON, 3822 CSS$$Commands::getLocationForSelector, 3823 CSS.SourceRange[].class 3824 ); 3825 } 3826 3827 /** 3828 * <CODE>[No Description Provided by Google]</CODE> 3829 * 3830 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 3831 * 3832 * @param shorthandName - 3833 * 3834 * @param value - 3835 * 3836 * @return An instance of <CODE>{@link Script}<{@link CSS.CSSProperty}[]></CODE> 3837 * 3838 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 3839 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 3840 * <CODE><{@link CSS.CSSProperty}[]></CODE> will be returned 3841 * 3842 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 3843 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 3844 * be retrieved.</I> 3845 * 3846 * <BR /><BR /><DIV CLASS=JDHint> 3847 * This Browser Function's {@code Promise} returns: 3848 * <CODE>{@link CSS.CSSProperty}[] (<B>longhandProperties</B>)</CODE> 3849 * </DIV> 3850 */ 3851 public static Script<CSS.CSSProperty[]> getLonghandProperties 3852 (String shorthandName, String value) 3853 { 3854 // Convert all Method Parameters into a JSON Request-Object (as a String) 3855 final String requestJSON = WriteJSON.get( 3856 CSS$$Commands.getLonghandProperties$$, "CSS.getLonghandProperties", 3857 shorthandName, value 3858 ); 3859 3860 return new Script<>( 3861 Domains.CSS, "getLonghandProperties", requestJSON, 3862 CSS$$Commands::getLonghandProperties, 3863 CSS.CSSProperty[].class 3864 ); 3865 } 3866 3867 /** 3868 * Returns requested styles for a DOM node identified by <CODE>nodeId</CODE>. 3869 * 3870 * @param nodeId - 3871 * 3872 * @return An instance of <CODE>{@link Script}<{@link getMatchedStylesForNode$$RET}></CODE> 3873 * 3874 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 3875 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 3876 * <CODE><{@link getMatchedStylesForNode$$RET}></CODE> will be returned 3877 * 3878 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 3879 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 3880 * be retrieved.</I> 3881 * 3882 * <BR /><BR /><DIV CLASS=JDHint> 3883 * This Browser Function's {@code Promise} returns:{@link getMatchedStylesForNode$$RET} 3884 * A dedicated return type implies that the browser may return more than 1 datum 3885 * </DIV> 3886 */ 3887 public static Script<getMatchedStylesForNode$$RET> getMatchedStylesForNode(int nodeId) 3888 { 3889 // Build the JSON Request-Object (as a String); only 1 Parameter is passed 3890 final String requestJSON = WriteJSON.get 3891 (CDPTypes.PRIMITIVE_INT, "nodeId", false, "CSS.getMatchedStylesForNode", nodeId); 3892 3893 return new Script<>( 3894 Domains.CSS, "getMatchedStylesForNode", requestJSON, 3895 getMatchedStylesForNode$$RET::fromJSON, 3896 getMatchedStylesForNode$$RET.class 3897 ); 3898 } 3899 3900 /** 3901 * Returns all media queries parsed by the rendering engine. 3902 * 3903 * @return An instance of <CODE>{@link Script}<{@link CSS.CSSMedia}[]></CODE> 3904 * 3905 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 3906 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 3907 * <CODE><{@link CSS.CSSMedia}[]></CODE> will be returned 3908 * 3909 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 3910 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 3911 * be retrieved.</I> 3912 * 3913 * <BR /><BR /><DIV CLASS=JDHint> 3914 * This Browser Function's {@code Promise} returns: 3915 * <CODE>{@link CSS.CSSMedia}[] (<B>medias</B>)</CODE> 3916 * </DIV> 3917 */ 3918 public static Script<CSS.CSSMedia[]> getMediaQueries() 3919 { 3920 // Ultra-Simple Request JSON - Because this method has no parameters 3921 final String requestJSON = "{\"method\":\"CSS.getMediaQueries\"}"; 3922 3923 return new Script<>( 3924 Domains.CSS, "getMediaQueries", requestJSON, 3925 CSS$$Commands::getMediaQueries, 3926 CSS.CSSMedia[].class 3927 ); 3928 } 3929 3930 /** 3931 * Requests information about platform fonts which we used to render child TextNodes in the given 3932 * node. 3933 * 3934 * @param nodeId - 3935 * 3936 * @return An instance of <CODE>{@link Script}<{@link CSS.PlatformFontUsage}[]></CODE> 3937 * 3938 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 3939 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 3940 * <CODE><{@link CSS.PlatformFontUsage}[]></CODE> will be returned 3941 * 3942 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 3943 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 3944 * be retrieved.</I> 3945 * 3946 * <BR /><BR /><DIV CLASS=JDHint> 3947 * This Browser Function's {@code Promise} returns: 3948 * <CODE>{@link CSS.PlatformFontUsage}[] (<B>fonts</B>)</CODE> 3949 * <BR /> 3950 * Usage statistics for every employed platform font. 3951 * </DIV> 3952 */ 3953 public static Script<CSS.PlatformFontUsage[]> getPlatformFontsForNode(int nodeId) 3954 { 3955 // Build the JSON Request-Object (as a String); only 1 Parameter is passed 3956 final String requestJSON = WriteJSON.get 3957 (CDPTypes.PRIMITIVE_INT, "nodeId", false, "CSS.getPlatformFontsForNode", nodeId); 3958 3959 return new Script<>( 3960 Domains.CSS, "getPlatformFontsForNode", requestJSON, 3961 CSS$$Commands::getPlatformFontsForNode, 3962 CSS.PlatformFontUsage[].class 3963 ); 3964 } 3965 3966 /** 3967 * Returns the current textual content for a stylesheet. 3968 * 3969 * @param styleSheetId - 3970 * 3971 * @return An instance of <CODE>{@link Script}<String></CODE> 3972 * 3973 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 3974 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 3975 * <CODE><String></CODE> will be returned 3976 * 3977 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 3978 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 3979 * be retrieved.</I> 3980 * 3981 * <BR /><BR /><DIV CLASS=JDHint> 3982 * This Browser Function's {@code Promise} returns: 3983 * <CODE>String (<B>text</B>)</CODE> 3984 * <BR /> 3985 * The stylesheet text. 3986 * </DIV> 3987 */ 3988 public static Script<String> getStyleSheetText(String styleSheetId) 3989 { 3990 // Build the JSON Request-Object (as a String); only 1 Parameter is passed 3991 final String requestJSON = WriteJSON.get 3992 (CDPTypes.STRING, "styleSheetId", false, "CSS.getStyleSheetText", styleSheetId); 3993 3994 return new Script<>( 3995 Domains.CSS, "getStyleSheetText", requestJSON, 3996 jo -> ReadJSON.getString(jo, "text", true, false), 3997 String.class 3998 ); 3999 } 4000 4001 /** 4002 * Resolve the specified values in the context of the provided element. 4003 * For example, a value of '1em' is evaluated according to the computed 4004 * 'font-size' of the element and a value 'calc(1px + 2px)' will be 4005 * resolved to '3px'. 4006 * If the <CODE>propertyName</CODE> was specified the <CODE>values</CODE> are resolved as if 4007 * they were property's declaration. If a value cannot be parsed according 4008 * to the provided property syntax, the value is parsed using combined 4009 * syntax as if null <CODE>propertyName</CODE> was provided. If the value cannot be 4010 * resolved even then, return the provided value without any changes. 4011 * 4012 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 4013 * 4014 * <BR /><BR /><DIV CLASS=JDHint> 4015 * 👍 Because of the sheer number of input parameters to this method, there is a 4016 * a {@link CommandBuilder} variant to this method which may be invoked instead. 4017 * 4018 * <BR /><BR /> 4019 * Please View: {@link #resolveValues()} 4020 * </DIV> 4021 * 4022 * @param values 4023 * Substitution functions (var()/env()/attr()) and cascade-dependent 4024 * keywords (revert/revert-layer) do not work. 4025 * 4026 * @param nodeId Id of the node in whose context the expression is evaluated 4027 * 4028 * @param propertyName Only longhands and custom property names are accepted. 4029 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 4030 * 4031 * @param pseudoType 4032 * Pseudo element type, only works for pseudo elements that generate 4033 * elements in the tree, such as ::before and ::after. 4034 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 4035 * 4036 * @param pseudoIdentifier Pseudo element custom ident. 4037 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 4038 * 4039 * @return An instance of <CODE>{@link Script}<String[]></CODE> 4040 * 4041 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 4042 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 4043 * <CODE><String[]></CODE> will be returned 4044 * 4045 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 4046 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 4047 * be retrieved.</I> 4048 * 4049 * <BR /><BR /><DIV CLASS=JDHint> 4050 * This Browser Function's {@code Promise} returns: 4051 * <CODE>String[] (<B>results</B>)</CODE> 4052 * </DIV> 4053 */ 4054 public static Script<String[]> resolveValues( 4055 String[] values, int nodeId, String propertyName, String pseudoType, 4056 String pseudoIdentifier 4057 ) 4058 { 4059 // Convert all Method Parameters into a JSON Request-Object (as a String) 4060 final String requestJSON = WriteJSON.get( 4061 CSS$$Commands.resolveValues$$, "CSS.resolveValues", 4062 values, nodeId, propertyName, pseudoType, pseudoIdentifier 4063 ); 4064 4065 return new Script<>( 4066 Domains.CSS, "resolveValues", requestJSON, 4067 CSS$$Commands::resolveValues, 4068 String[].class 4069 ); 4070 } 4071 4072 /** 4073 * Modifies the expression of a container query. 4074 * 4075 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 4076 * 4077 * @param styleSheetId - 4078 * 4079 * @param range - 4080 * 4081 * @param text - 4082 * 4083 * @return An instance of <CODE>{@link Script}<{@link CSS.CSSContainerQuery}></CODE> 4084 * 4085 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 4086 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 4087 * <CODE><{@link CSS.CSSContainerQuery}></CODE> will be returned 4088 * 4089 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 4090 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 4091 * be retrieved.</I> 4092 * 4093 * <BR /><BR /><DIV CLASS=JDHint> 4094 * This Browser Function's {@code Promise} returns: 4095 * <CODE>{@link CSS.CSSContainerQuery} (<B>containerQuery</B>)</CODE> 4096 * <BR /> 4097 * The resulting CSS container query rule after modification. 4098 * </DIV> 4099 */ 4100 public static Script<CSS.CSSContainerQuery> setContainerQueryText 4101 (String styleSheetId, SourceRange range, String text) 4102 { 4103 // Convert all Method Parameters into a JSON Request-Object (as a String) 4104 final String requestJSON = WriteJSON.get( 4105 CSS$$Commands.setContainerQueryText$$, "CSS.setContainerQueryText", 4106 styleSheetId, range, text 4107 ); 4108 4109 return new Script<>( 4110 Domains.CSS, "setContainerQueryText", requestJSON, 4111 CSS$$Commands::setContainerQueryText, 4112 CSS.CSSContainerQuery.class 4113 ); 4114 } 4115 4116 /** 4117 * Find a rule with the given active property for the given node and set the new value for this 4118 * property 4119 * 4120 * @param nodeId The element id for which to set property. 4121 * 4122 * @param propertyName - 4123 * 4124 * @param value - 4125 * 4126 * @return An instance of <CODE>{@link Script}<Void></CODE> 4127 * 4128 * <BR /><BR />This {@code Script} instance must be <B STYLE='color:red'>executed</B> before the 4129 * browser receives the invocation-request. 4130 * 4131 * <BR /><BR /><DIV CLASS=JDHint> 4132 * This Browser-Function <I>does not have</I> a return-value. You may choose to 4133 * <B STYLE='color: red'>await</B> the {@link Promise}{@code <Void>} to ensure that 4134 * the Browser Function has run to completion. 4135 * </DIV> 4136 */ 4137 public static Script<Void> setEffectivePropertyValueForNode 4138 (int nodeId, String propertyName, String value) 4139 { 4140 // Convert all Method Parameters into a JSON Request-Object (as a String) 4141 final String requestJSON = WriteJSON.get( 4142 CSS$$Commands.setEffectivePropertyValueForNode$$, 4143 "CSS.setEffectivePropertyValueForNode", 4144 nodeId, propertyName, value 4145 ); 4146 4147 return Script.NO_RET(Domains.CSS, "setEffectivePropertyValueForNode", requestJSON); 4148 } 4149 4150 /** 4151 * Modifies the keyframe rule key text. 4152 * 4153 * @param styleSheetId - 4154 * 4155 * @param range - 4156 * 4157 * @param keyText - 4158 * 4159 * @return An instance of <CODE>{@link Script}<{@link CSS.Value}></CODE> 4160 * 4161 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 4162 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 4163 * <CODE><{@link CSS.Value}></CODE> will be returned 4164 * 4165 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 4166 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 4167 * be retrieved.</I> 4168 * 4169 * <BR /><BR /><DIV CLASS=JDHint> 4170 * This Browser Function's {@code Promise} returns: 4171 * <CODE>{@link CSS.Value} (<B>keyText</B>)</CODE> 4172 * <BR /> 4173 * The resulting key text after modification. 4174 * </DIV> 4175 */ 4176 public static Script<CSS.Value> setKeyframeKey 4177 (String styleSheetId, SourceRange range, String keyText) 4178 { 4179 // Convert all Method Parameters into a JSON Request-Object (as a String) 4180 final String requestJSON = WriteJSON.get( 4181 CSS$$Commands.setKeyframeKey$$, "CSS.setKeyframeKey", 4182 styleSheetId, range, keyText 4183 ); 4184 4185 return new Script<>( 4186 Domains.CSS, "setKeyframeKey", requestJSON, 4187 CSS$$Commands::setKeyframeKey, 4188 CSS.Value.class 4189 ); 4190 } 4191 4192 /** 4193 * Enables/disables rendering of local CSS fonts (enabled by default). 4194 * 4195 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 4196 * 4197 * @param enabled Whether rendering of local fonts is enabled. 4198 * 4199 * @return An instance of <CODE>{@link Script}<Void></CODE> 4200 * 4201 * <BR /><BR />This {@code Script} instance must be <B STYLE='color:red'>executed</B> before the 4202 * browser receives the invocation-request. 4203 * 4204 * <BR /><BR /><DIV CLASS=JDHint> 4205 * This Browser-Function <I>does not have</I> a return-value. You may choose to 4206 * <B STYLE='color: red'>await</B> the {@link Promise}{@code <Void>} to ensure that 4207 * the Browser Function has run to completion. 4208 * </DIV> 4209 */ 4210 public static Script<Void> setLocalFontsEnabled(boolean enabled) 4211 { 4212 // Build the JSON Request-Object (as a String); only 1 Parameter is passed 4213 final String requestJSON = WriteJSON.get 4214 (CDPTypes.PRIMITIVE_BOOLEAN, "enabled", false, "CSS.setLocalFontsEnabled", enabled); 4215 4216 return Script.NO_RET(Domains.CSS, "setLocalFontsEnabled", requestJSON); 4217 } 4218 4219 /** 4220 * Modifies the rule selector. 4221 * 4222 * @param styleSheetId - 4223 * 4224 * @param range - 4225 * 4226 * @param text - 4227 * 4228 * @return An instance of <CODE>{@link Script}<{@link CSS.CSSMedia}></CODE> 4229 * 4230 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 4231 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 4232 * <CODE><{@link CSS.CSSMedia}></CODE> will be returned 4233 * 4234 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 4235 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 4236 * be retrieved.</I> 4237 * 4238 * <BR /><BR /><DIV CLASS=JDHint> 4239 * This Browser Function's {@code Promise} returns: 4240 * <CODE>{@link CSS.CSSMedia} (<B>media</B>)</CODE> 4241 * <BR /> 4242 * The resulting CSS media rule after modification. 4243 * </DIV> 4244 */ 4245 public static Script<CSS.CSSMedia> setMediaText 4246 (String styleSheetId, SourceRange range, String text) 4247 { 4248 // Convert all Method Parameters into a JSON Request-Object (as a String) 4249 final String requestJSON = WriteJSON.get( 4250 CSS$$Commands.setMediaText$$, "CSS.setMediaText", 4251 styleSheetId, range, text 4252 ); 4253 4254 return new Script<>( 4255 Domains.CSS, "setMediaText", requestJSON, 4256 CSS$$Commands::setMediaText, 4257 CSS.CSSMedia.class 4258 ); 4259 } 4260 4261 /** 4262 * Modifies the property rule property name. 4263 * 4264 * @param styleSheetId - 4265 * 4266 * @param range - 4267 * 4268 * @param propertyName - 4269 * 4270 * @return An instance of <CODE>{@link Script}<{@link CSS.Value}></CODE> 4271 * 4272 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 4273 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 4274 * <CODE><{@link CSS.Value}></CODE> will be returned 4275 * 4276 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 4277 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 4278 * be retrieved.</I> 4279 * 4280 * <BR /><BR /><DIV CLASS=JDHint> 4281 * This Browser Function's {@code Promise} returns: 4282 * <CODE>{@link CSS.Value} (<B>propertyName</B>)</CODE> 4283 * <BR /> 4284 * The resulting key text after modification. 4285 * </DIV> 4286 */ 4287 public static Script<CSS.Value> setPropertyRulePropertyName 4288 (String styleSheetId, SourceRange range, String propertyName) 4289 { 4290 // Convert all Method Parameters into a JSON Request-Object (as a String) 4291 final String requestJSON = WriteJSON.get( 4292 CSS$$Commands.setPropertyRulePropertyName$$, "CSS.setPropertyRulePropertyName", 4293 styleSheetId, range, propertyName 4294 ); 4295 4296 return new Script<>( 4297 Domains.CSS, "setPropertyRulePropertyName", requestJSON, 4298 CSS$$Commands::setPropertyRulePropertyName, 4299 CSS.Value.class 4300 ); 4301 } 4302 4303 /** 4304 * Modifies the rule selector. 4305 * 4306 * @param styleSheetId - 4307 * 4308 * @param range - 4309 * 4310 * @param selector - 4311 * 4312 * @return An instance of <CODE>{@link Script}<{@link CSS.SelectorList}></CODE> 4313 * 4314 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 4315 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 4316 * <CODE><{@link CSS.SelectorList}></CODE> will be returned 4317 * 4318 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 4319 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 4320 * be retrieved.</I> 4321 * 4322 * <BR /><BR /><DIV CLASS=JDHint> 4323 * This Browser Function's {@code Promise} returns: 4324 * <CODE>{@link CSS.SelectorList} (<B>selectorList</B>)</CODE> 4325 * <BR /> 4326 * The resulting selector list after modification. 4327 * </DIV> 4328 */ 4329 public static Script<CSS.SelectorList> setRuleSelector 4330 (String styleSheetId, SourceRange range, String selector) 4331 { 4332 // Convert all Method Parameters into a JSON Request-Object (as a String) 4333 final String requestJSON = WriteJSON.get( 4334 CSS$$Commands.setRuleSelector$$, "CSS.setRuleSelector", 4335 styleSheetId, range, selector 4336 ); 4337 4338 return new Script<>( 4339 Domains.CSS, "setRuleSelector", requestJSON, 4340 CSS$$Commands::setRuleSelector, 4341 CSS.SelectorList.class 4342 ); 4343 } 4344 4345 /** 4346 * Modifies the expression of a scope at-rule. 4347 * 4348 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 4349 * 4350 * @param styleSheetId - 4351 * 4352 * @param range - 4353 * 4354 * @param text - 4355 * 4356 * @return An instance of <CODE>{@link Script}<{@link CSS.CSSScope}></CODE> 4357 * 4358 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 4359 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 4360 * <CODE><{@link CSS.CSSScope}></CODE> will be returned 4361 * 4362 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 4363 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 4364 * be retrieved.</I> 4365 * 4366 * <BR /><BR /><DIV CLASS=JDHint> 4367 * This Browser Function's {@code Promise} returns: 4368 * <CODE>{@link CSS.CSSScope} (<B>scope</B>)</CODE> 4369 * <BR /> 4370 * The resulting CSS Scope rule after modification. 4371 * </DIV> 4372 */ 4373 public static Script<CSS.CSSScope> setScopeText 4374 (String styleSheetId, SourceRange range, String text) 4375 { 4376 // Convert all Method Parameters into a JSON Request-Object (as a String) 4377 final String requestJSON = WriteJSON.get( 4378 CSS$$Commands.setScopeText$$, "CSS.setScopeText", 4379 styleSheetId, range, text 4380 ); 4381 4382 return new Script<>( 4383 Domains.CSS, "setScopeText", requestJSON, 4384 CSS$$Commands::setScopeText, 4385 CSS.CSSScope.class 4386 ); 4387 } 4388 4389 /** 4390 * Sets the new stylesheet text. 4391 * 4392 * @param styleSheetId - 4393 * 4394 * @param text - 4395 * 4396 * @return An instance of <CODE>{@link Script}<String></CODE> 4397 * 4398 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 4399 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 4400 * <CODE><String></CODE> will be returned 4401 * 4402 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 4403 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 4404 * be retrieved.</I> 4405 * 4406 * <BR /><BR /><DIV CLASS=JDHint> 4407 * This Browser Function's {@code Promise} returns: 4408 * <CODE>String (<B>sourceMapURL</B>)</CODE> 4409 * <BR /> 4410 * URL of source map associated with script (if any). 4411 * </DIV> 4412 */ 4413 public static Script<String> setStyleSheetText(String styleSheetId, String text) 4414 { 4415 // Convert all Method Parameters into a JSON Request-Object (as a String) 4416 final String requestJSON = WriteJSON.get( 4417 CSS$$Commands.setStyleSheetText$$, "CSS.setStyleSheetText", 4418 styleSheetId, text 4419 ); 4420 4421 return new Script<>( 4422 Domains.CSS, "setStyleSheetText", requestJSON, 4423 jo -> ReadJSON.getString(jo, "sourceMapURL", true, false), 4424 String.class 4425 ); 4426 } 4427 4428 /** 4429 * Applies specified style edits one after another in the given order. 4430 * 4431 * @param edits - 4432 * 4433 * @param nodeForPropertySyntaxValidation 4434 * NodeId for the DOM node in whose context custom property declarations for registered properties should be 4435 * validated. If omitted, declarations in the new rule text can only be validated statically, which may produce 4436 * incorrect results if the declaration contains a var() for example. 4437 * <BR /><B CLASS=Opt-Top>OPTIONAL</B><B CLASS=Exp-Top>EXPERIMENTAL</B> 4438 * 4439 * @return An instance of <CODE>{@link Script}<{@link CSS.CSSStyle}[]></CODE> 4440 * 4441 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 4442 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 4443 * <CODE><{@link CSS.CSSStyle}[]></CODE> will be returned 4444 * 4445 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 4446 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 4447 * be retrieved.</I> 4448 * 4449 * <BR /><BR /><DIV CLASS=JDHint> 4450 * This Browser Function's {@code Promise} returns: 4451 * <CODE>{@link CSS.CSSStyle}[] (<B>styles</B>)</CODE> 4452 * <BR /> 4453 * The resulting styles after modification. 4454 * </DIV> 4455 */ 4456 public static Script<CSS.CSSStyle[]> setStyleTexts 4457 (StyleDeclarationEdit[] edits, Integer nodeForPropertySyntaxValidation) 4458 { 4459 // Convert all Method Parameters into a JSON Request-Object (as a String) 4460 final String requestJSON = WriteJSON.get( 4461 CSS$$Commands.setStyleTexts$$, "CSS.setStyleTexts", 4462 edits, nodeForPropertySyntaxValidation 4463 ); 4464 4465 return new Script<>( 4466 Domains.CSS, "setStyleTexts", requestJSON, 4467 CSS$$Commands::setStyleTexts, 4468 CSS.CSSStyle[].class 4469 ); 4470 } 4471 4472 /** 4473 * Modifies the expression of a supports at-rule. 4474 * 4475 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 4476 * 4477 * @param styleSheetId - 4478 * 4479 * @param range - 4480 * 4481 * @param text - 4482 * 4483 * @return An instance of <CODE>{@link Script}<{@link CSS.CSSSupports}></CODE> 4484 * 4485 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 4486 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 4487 * <CODE><{@link CSS.CSSSupports}></CODE> will be returned 4488 * 4489 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 4490 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 4491 * be retrieved.</I> 4492 * 4493 * <BR /><BR /><DIV CLASS=JDHint> 4494 * This Browser Function's {@code Promise} returns: 4495 * <CODE>{@link CSS.CSSSupports} (<B>supports</B>)</CODE> 4496 * <BR /> 4497 * The resulting CSS Supports rule after modification. 4498 * </DIV> 4499 */ 4500 public static Script<CSS.CSSSupports> setSupportsText 4501 (String styleSheetId, SourceRange range, String text) 4502 { 4503 // Convert all Method Parameters into a JSON Request-Object (as a String) 4504 final String requestJSON = WriteJSON.get( 4505 CSS$$Commands.setSupportsText$$, "CSS.setSupportsText", 4506 styleSheetId, range, text 4507 ); 4508 4509 return new Script<>( 4510 Domains.CSS, "setSupportsText", requestJSON, 4511 CSS$$Commands::setSupportsText, 4512 CSS.CSSSupports.class 4513 ); 4514 } 4515 4516 /** 4517 * Enables the selector recording. 4518 * 4519 * @return An instance of <CODE>{@link Script}<Void></CODE> 4520 * 4521 * <BR /><BR />This {@code Script} instance must be <B STYLE='color:red'>executed</B> before the 4522 * browser receives the invocation-request. 4523 * 4524 * <BR /><BR /><DIV CLASS=JDHint> 4525 * This Browser-Function <I>does not have</I> a return-value. You may choose to 4526 * <B STYLE='color: red'>await</B> the {@link Promise}{@code <Void>} to ensure that 4527 * the Browser Function has run to completion. 4528 * </DIV> 4529 */ 4530 public static Script<Void> startRuleUsageTracking() 4531 { 4532 // Ultra-Simple Request JSON - Because this method has no parameters 4533 final String requestJSON = "{\"method\":\"CSS.startRuleUsageTracking\"}"; 4534 4535 return Script.NO_RET(Domains.CSS, "startRuleUsageTracking", requestJSON); 4536 } 4537 4538 /** 4539 * Stop tracking rule usage and return the list of rules that were used since last call to 4540 * <CODE>takeCoverageDelta</CODE> (or since start of coverage instrumentation). 4541 * 4542 * @return An instance of <CODE>{@link Script}<{@link CSS.RuleUsage}[]></CODE> 4543 * 4544 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 4545 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 4546 * <CODE><{@link CSS.RuleUsage}[]></CODE> will be returned 4547 * 4548 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 4549 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 4550 * be retrieved.</I> 4551 * 4552 * <BR /><BR /><DIV CLASS=JDHint> 4553 * This Browser Function's {@code Promise} returns: 4554 * <CODE>{@link CSS.RuleUsage}[] (<B>ruleUsage</B>)</CODE> 4555 * </DIV> 4556 */ 4557 public static Script<CSS.RuleUsage[]> stopRuleUsageTracking() 4558 { 4559 // Ultra-Simple Request JSON - Because this method has no parameters 4560 final String requestJSON = "{\"method\":\"CSS.stopRuleUsageTracking\"}"; 4561 4562 return new Script<>( 4563 Domains.CSS, "stopRuleUsageTracking", requestJSON, 4564 CSS$$Commands::stopRuleUsageTracking, 4565 CSS.RuleUsage[].class 4566 ); 4567 } 4568 4569 /** 4570 * Polls the next batch of computed style updates. 4571 * 4572 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 4573 * 4574 * @return An instance of <CODE>{@link Script}<int[]></CODE> 4575 * 4576 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 4577 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 4578 * <CODE><int[]></CODE> will be returned 4579 * 4580 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 4581 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 4582 * be retrieved.</I> 4583 * 4584 * <BR /><BR /><DIV CLASS=JDHint> 4585 * This Browser Function's {@code Promise} returns: 4586 * <CODE>int[] (<B>nodeIds</B>)</CODE> 4587 * <BR /> 4588 * The list of node Ids that have their tracked computed styles updated. 4589 * </DIV> 4590 */ 4591 public static Script<int[]> takeComputedStyleUpdates() 4592 { 4593 // Ultra-Simple Request JSON - Because this method has no parameters 4594 final String requestJSON = "{\"method\":\"CSS.takeComputedStyleUpdates\"}"; 4595 4596 return new Script<>( 4597 Domains.CSS, "takeComputedStyleUpdates", requestJSON, 4598 CSS$$Commands::takeComputedStyleUpdates, 4599 int[].class 4600 ); 4601 } 4602 4603 /** 4604 * Obtain list of rules that became used since last call to this method (or since start of coverage 4605 * instrumentation). 4606 * 4607 * @return An instance of <CODE>{@link Script}<{@link takeCoverageDelta$$RET}></CODE> 4608 * 4609 * <BR /><BR />This <B>script</B> may be <B STYLE='color: red'>executed</B>, using 4610 * {@link Script#exec(WebSocketSender) Script.exec}, and afterwards, a {@link Promise} 4611 * <CODE><{@link takeCoverageDelta$$RET}></CODE> will be returned 4612 * 4613 * <BR /><BR />Finally, the <B>{@code Promise}</B> may be <B STYLE='color: red'>awaited</B>, 4614 * using {@link Promise#await()}, <I>and the returned result of this Browser Function may 4615 * be retrieved.</I> 4616 * 4617 * <BR /><BR /><DIV CLASS=JDHint> 4618 * This Browser Function's {@code Promise} returns:{@link takeCoverageDelta$$RET} 4619 * A dedicated return type implies that the browser may return more than 1 datum 4620 * </DIV> 4621 */ 4622 public static Script<takeCoverageDelta$$RET> takeCoverageDelta() 4623 { 4624 // Ultra-Simple Request JSON - Because this method has no parameters 4625 final String requestJSON = "{\"method\":\"CSS.takeCoverageDelta\"}"; 4626 4627 return new Script<>( 4628 Domains.CSS, "takeCoverageDelta", requestJSON, 4629 takeCoverageDelta$$RET::fromJSON, 4630 takeCoverageDelta$$RET.class 4631 ); 4632 } 4633 4634 /** 4635 * Starts tracking the given computed styles for updates. The specified array of properties 4636 * replaces the one previously specified. Pass empty array to disable tracking. 4637 * Use takeComputedStyleUpdates to retrieve the list of nodes that had properties modified. 4638 * The changes to computed style properties are only tracked for nodes pushed to the front-end 4639 * by the DOM agent. If no changes to the tracked properties occur after the node has been pushed 4640 * to the front-end, no updates will be issued for the node. 4641 * 4642 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 4643 * 4644 * @param propertiesToTrack - 4645 * 4646 * @return An instance of <CODE>{@link Script}<Void></CODE> 4647 * 4648 * <BR /><BR />This {@code Script} instance must be <B STYLE='color:red'>executed</B> before the 4649 * browser receives the invocation-request. 4650 * 4651 * <BR /><BR /><DIV CLASS=JDHint> 4652 * This Browser-Function <I>does not have</I> a return-value. You may choose to 4653 * <B STYLE='color: red'>await</B> the {@link Promise}{@code <Void>} to ensure that 4654 * the Browser Function has run to completion. 4655 * </DIV> 4656 */ 4657 public static Script<Void> trackComputedStyleUpdates 4658 (CSSComputedStyleProperty[] propertiesToTrack) 4659 { 4660 // Build the JSON Request-Object (as a String); only 1 Parameter is passed 4661 final String requestJSON = WriteJSON.get( 4662 CDPTypes.CDP_TYPE_ARRAY_1D, "propertiesToTrack", false, 4663 "CSS.trackComputedStyleUpdates", (Object) propertiesToTrack 4664 ); 4665 4666 return Script.NO_RET(Domains.CSS, "trackComputedStyleUpdates", requestJSON); 4667 } 4668 4669 /** 4670 * Starts tracking the given node for the computed style updates 4671 * and whenever the computed style is updated for node, it queues 4672 * a <CODE>computedStyleUpdated</CODE> event with throttling. 4673 * There can only be 1 node tracked for computed style updates 4674 * so passing a new node id removes tracking from the previous node. 4675 * Pass <CODE>undefined</CODE> to disable tracking. 4676 * 4677 * <BR /><B CLASS=Exp-Top>EXPERIMENTAL</B> 4678 * 4679 * @param nodeId - 4680 * <BR /><B CLASS=Opt-Top>OPTIONAL</B> 4681 * 4682 * @return An instance of <CODE>{@link Script}<Void></CODE> 4683 * 4684 * <BR /><BR />This {@code Script} instance must be <B STYLE='color:red'>executed</B> before the 4685 * browser receives the invocation-request. 4686 * 4687 * <BR /><BR /><DIV CLASS=JDHint> 4688 * This Browser-Function <I>does not have</I> a return-value. You may choose to 4689 * <B STYLE='color: red'>await</B> the {@link Promise}{@code <Void>} to ensure that 4690 * the Browser Function has run to completion. 4691 * </DIV> 4692 */ 4693 public static Script<Void> trackComputedStyleUpdatesForNode(Integer nodeId) 4694 { 4695 // Build the JSON Request-Object (as a String); only 1 Parameter is passed 4696 final String requestJSON = WriteJSON.get( 4697 CDPTypes.BOXED_INTEGER, "nodeId", true, "CSS.trackComputedStyleUpdatesForNode", 4698 nodeId 4699 ); 4700 4701 return Script.NO_RET(Domains.CSS, "trackComputedStyleUpdatesForNode", requestJSON); 4702 } 4703 4704 4705 // ******************************************************************************************** 4706 // ******************************************************************************************** 4707 // CommandBuilder Getter-Methods 4708 // ******************************************************************************************** 4709 // ******************************************************************************************** 4710 4711 4712 /** 4713 * Creates a buider for conveniently assigning parameters to this method. 4714 * 4715 * <BR /><BR /><DIV CLASS=JDHint> 4716 * Note that the original method expects 5 parameters, and can be cumbersome. 4717 * </DIV> 4718 * 4719 * @return {@link CommandBuilder} instance, for assigning parameter values, one by one. 4720 * @see #resolveValues 4721 */ 4722 public static CommandBuilder<String[]> resolveValues() 4723 { return CommandBuilder.builder(CSS$$Commands.resolveValues$$); } 4724 4725 4726}