Package Torello.Browser.BrowserAPI
Class DOM.Node
- java.lang.Object
-
- Torello.Browser.BaseType<DOM.Node>
-
- Torello.Browser.BrowserAPI.DOM.Node
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Comparable<BaseType<?>>
- Enclosing class:
- DOM
public static class DOM.Node extends BaseType<DOM.Node> implements java.io.Serializable
This Nested Java Class is declared as a "Type", which is similar to a Java Class. The CDP API Specifications list this type among the types, events & commands located in theDOMdomain, which may be found within theBrowserAPI.
📌 All browser domain type classes will have a class name that begins with an upper case letter.DOM interaction is implemented in terms of mirror objects that represent the actual DOM nodes. DOMNode is a base node mirror type.- See Also:
- Serialized Form
Hi-Lited Source-Code:This File's Source Code:
- View Here: Torello/Browser/BrowserAPI/DOM.java
- Open New Browser-Tab: Torello/Browser/BrowserAPI/DOM.java
File Size: 9,897 Bytes Line Count: 267 '\n' Characters Found
Helper: Equals, HashCode, toJSON, etc
- View Here: DOM$$Node$$.java
- Open New Browser-Tab: DOM$$Node$$.java
File Size: 29,209 Bytes Line Count: 675 '\n' Characters Found
-
-
Field Summary
Serializable ID Modifier and Type Field Description protected static longserialVersionUIDType Fields / Properties (from Google & Browser Specs) Modifier and Type Field Description DOM.BackendNodeassignedSlot[No Description Provided by Google]String[]attributesAttributes of theElementnode in the form of flat array[name1, value1, name2, value2].intbackendNodeIdThe BackendNodeId for this node.StringbaseURLBase URL thatDocumentorFrameOwnernode uses for URL completion.IntegerchildNodeCountChild count forContainernodes.DOM.Node[]childrenChild nodes of this node when requested with children.StringcompatibilityMode[No Description Provided by Google]DOM.NodecontentDocumentContent document for frame owner elements.DOM.BackendNode[]distributedNodesDistributed nodes for given insertion point.StringdocumentURLDocument URL thatDocumentorFrameOwnernode points to.StringframeIdFrame ID for frame owner elements.DOM.NodeimportedDocumentDeprecated, as the HTML Imports API has been removed (crbug.com/937746).StringinternalSubsetDocumentType's internalSubset.BooleanisScrollable[No Description Provided by Google]BooleanisSVGWhether the node is SVG.StringlocalNameNode's localName.StringnameAttr's name.intnodeIdNode identifier that is passed into the rest of the DOM messages as thenodeId.StringnodeNameNode's nodeName.intnodeTypeNode's nodeType.StringnodeValueNode's nodeValue.IntegerparentIdThe id of the parent node if any.DOM.Node[]pseudoElementsPseudo elements associated with this node.StringpseudoIdentifierPseudo element identifier for this node.StringpseudoTypePseudo element type for this node.StringpublicIdDocumentType's publicId.DOM.Node[]shadowRootsShadow root list for given element host.StringshadowRootTypeShadow root type.StringsystemIdDocumentType's systemId.DOM.NodetemplateContentContent document fragment for template elements.StringvalueAttr's value.StringxmlVersionDocument's XML version in case of XML documents.-
Fields inherited from class Torello.Browser.BaseType
domain, helperSingleton, isPresent, numFields
-
-
Constructor Summary
Constructors Constructor Description Node(ReadOnlyList<Boolean> isPresent, int nodeId, Integer parentId, int backendNodeId, int nodeType, String nodeName, String localName, String nodeValue, Integer childNodeCount, DOM.Node[] children, String[] attributes, String documentURL, String baseURL, String publicId, String systemId, String internalSubset, String xmlVersion, String name, String value, String pseudoType, String pseudoIdentifier, String shadowRootType, String frameId, DOM.Node contentDocument, DOM.Node[] shadowRoots, DOM.Node templateContent, DOM.Node[] pseudoElements, DOM.Node importedDocument, DOM.BackendNode[] distributedNodes, Boolean isSVG, String compatibilityMode, DOM.BackendNode assignedSlot, Boolean isScrollable)Constructor.
-
Method Summary
Static Builder Convert a JsonObject to a POJO Modifier and Type Method Description static DOM.NodefromJSON(JsonObject jo)Creates an instance of this class from aJsonObject.Retrieve the Type-Descriptor Singleton-Instance for this Nested Class. Modifier and Type Method Description static NestedDescriptor<DOM.Node>descriptor()Returns this class'sNestedDescriptorsingleton-instance.-
Methods inherited from class Torello.Browser.BaseType
allEnumStrROLs, compareTo, enumStrList, enumStrValidate, enumStrValidateThrow, equals, hashCode, isPresent, optionalsValidate, optionalsValidateThrow, toJSON, toString
-
-
-
-
Field Detail
-
serialVersionUID
protected static final long serialVersionUID
This fulfils the SerialVersion UID requirement for all classes that implement Java'sinterface java.io.Serializable. Using theSerializableImplementation offered by java is very easy, and can make saving program state when debugging a lot easier. It can also be used in place of more complicated systems like "hibernate" to store data as well.- See Also:
- Constant Field Values
-
nodeId
public final int nodeId
Node identifier that is passed into the rest of the DOM messages as thenodeId. Backend will only push node with givenidonce. It is aware of all requested nodes and will only fire DOM events for nodes known to the client.
-
parentId
public final java.lang.Integer parentId
The id of the parent node if any.
OPTIONAL
-
backendNodeId
public final int backendNodeId
The BackendNodeId for this node.
-
nodeType
public final int nodeType
Node's nodeType.
-
nodeName
public final java.lang.String nodeName
Node's nodeName.
-
localName
public final java.lang.String localName
Node's localName.
-
nodeValue
public final java.lang.String nodeValue
Node's nodeValue.
-
childNodeCount
public final java.lang.Integer childNodeCount
Child count forContainernodes.
OPTIONAL
-
children
-
attributes
public final java.lang.String[] attributes
Attributes of theElementnode in the form of flat array[name1, value1, name2, value2].
OPTIONAL
-
documentURL
public final java.lang.String documentURL
Document URL thatDocumentorFrameOwnernode points to.
OPTIONAL
-
baseURL
public final java.lang.String baseURL
Base URL thatDocumentorFrameOwnernode uses for URL completion.
OPTIONAL
-
publicId
public final java.lang.String publicId
DocumentType's publicId.
OPTIONAL
-
systemId
public final java.lang.String systemId
DocumentType's systemId.
OPTIONAL
-
internalSubset
public final java.lang.String internalSubset
DocumentType's internalSubset.
OPTIONAL
-
xmlVersion
public final java.lang.String xmlVersion
Document's XML version in case of XML documents.
OPTIONAL
-
name
public final java.lang.String name
Attr's name.
OPTIONAL
-
value
public final java.lang.String value
Attr's value.
OPTIONAL
-
pseudoType
public final java.lang.String pseudoType
Pseudo element type for this node.
OPTIONALThis particular field will have its values resricted to the contents of a CDP defined Enumerated String List. That list may be viewed here:
📎DOM.PseudoType
Programmatically Accessing the Enum:
// Retrieve the list of enumerated strings for this field ReadOnlyList<String> enumerationStrs = DOM.PseudoType.enumStrList("pseudoType"); // Print the list of strings to the terminal for (final String s : enumerationStrs) System.out.println('\"' + s + "\", ");
- See Also:
BaseType.enumStrList(String)
-
pseudoIdentifier
public final java.lang.String pseudoIdentifier
Pseudo element identifier for this node. Only present if there is a valid pseudoType.
OPTIONAL
-
shadowRootType
public final java.lang.String shadowRootType
Shadow root type.
OPTIONALThis particular field will have its values resricted to the contents of a CDP defined Enumerated String List. That list may be viewed here:
📎DOM.ShadowRootType
Programmatically Accessing the Enum:
// Retrieve the list of enumerated strings for this field ReadOnlyList<String> enumerationStrs = DOM.ShadowRootType.enumStrList("shadowRootType"); // Print the list of strings to the terminal for (final String s : enumerationStrs) System.out.println('\"' + s + "\", ");
- See Also:
BaseType.enumStrList(String)
-
frameId
public final java.lang.String frameId
Frame ID for frame owner elements.
OPTIONAL
-
contentDocument
public final DOM.Node contentDocument
Content document for frame owner elements.
OPTIONAL
-
shadowRoots
public final DOM.Node[] shadowRoots
Shadow root list for given element host.
OPTIONAL
-
templateContent
public final DOM.Node templateContent
Content document fragment for template elements.
OPTIONAL
-
pseudoElements
public final DOM.Node[] pseudoElements
Pseudo elements associated with this node.
OPTIONAL
-
importedDocument
public final DOM.Node importedDocument
Deprecated, as the HTML Imports API has been removed (crbug.com/937746). This property used to return the imported document for the HTMLImport links. The property is always undefined now.
OPTIONALDEPRECATED
-
distributedNodes
public final DOM.BackendNode[] distributedNodes
Distributed nodes for given insertion point.
OPTIONAL
-
isSVG
public final java.lang.Boolean isSVG
Whether the node is SVG.
OPTIONAL
-
compatibilityMode
public final java.lang.String compatibilityMode
[No Description Provided by Google]
OPTIONALThis particular field will have its values resricted to the contents of a CDP defined Enumerated String List. That list may be viewed here:
📎DOM.CompatibilityMode
Programmatically Accessing the Enum:
// Retrieve the list of enumerated strings for this field ReadOnlyList<String> enumerationStrs = DOM.CompatibilityMode.enumStrList("compatibilityMode"); // Print the list of strings to the terminal for (final String s : enumerationStrs) System.out.println('\"' + s + "\", ");
- See Also:
BaseType.enumStrList(String)
-
assignedSlot
public final DOM.BackendNode assignedSlot
[No Description Provided by Google]
OPTIONAL
-
isScrollable
public final java.lang.Boolean isScrollable
[No Description Provided by Google]
OPTIONALEXPERIMENTAL
-
-
Constructor Detail
-
Node
public Node(ReadOnlyList<java.lang.Boolean> isPresent, int nodeId, java.lang.Integer parentId, int backendNodeId, int nodeType, java.lang.String nodeName, java.lang.String localName, java.lang.String nodeValue, java.lang.Integer childNodeCount, DOM.Node[] children, java.lang.String[] attributes, java.lang.String documentURL, java.lang.String baseURL, java.lang.String publicId, java.lang.String systemId, java.lang.String internalSubset, java.lang.String xmlVersion, java.lang.String name, java.lang.String value, java.lang.String pseudoType, java.lang.String pseudoIdentifier, java.lang.String shadowRootType, java.lang.String frameId, DOM.Node contentDocument, DOM.Node[] shadowRoots, DOM.Node templateContent, DOM.Node[] pseudoElements, DOM.Node importedDocument, DOM.BackendNode[] distributedNodes, java.lang.Boolean isSVG, java.lang.String compatibilityMode, DOM.BackendNode assignedSlot, java.lang.Boolean isScrollable)
Constructor. Please review this class' fields for documentation.
-
-
Method Detail
-
fromJSON
public static DOM.Node fromJSON(JsonObject jo)
Creates an instance of this class from aJsonObject.- Code:
- Exact Method Body:
return singleton.fromJSON(jo);
-
descriptor
public static NestedDescriptor<DOM.Node> descriptor()
Returns this class'sNestedDescriptorsingleton-instance. class / type.- Code:
- Exact Method Body:
return singleton.descriptor();
-
-