Struct cdp::dom::Node
[−]
[src]
pub struct Node<'a> { pub node_id: NodeId, pub parent_id: Option<NodeId>, pub backend_node_id: BackendNodeId, pub node_type: i32, pub node_name: Cow<'a, str>, pub local_name: Cow<'a, str>, pub node_value: Cow<'a, str>, pub child_node_count: Option<i32>, pub children: Option<Vec<Box<Node<'a>>>>, pub attributes: Option<Vec<Cow<'a, str>>>, pub document_url: Option<Cow<'a, str>>, pub base_url: Option<Cow<'a, str>>, pub public_id: Option<Cow<'a, str>>, pub system_id: Option<Cow<'a, str>>, pub internal_subset: Option<Cow<'a, str>>, pub xml_version: Option<Cow<'a, str>>, pub name: Option<Cow<'a, str>>, pub value: Option<Cow<'a, str>>, pub pseudo_type: Option<PseudoType>, pub shadow_root_type: Option<ShadowRootType>, pub frame_id: Option<FrameId<'a>>, pub content_document: Option<Box<Node<'a>>>, pub shadow_roots: Option<Vec<Box<Node<'a>>>>, pub template_content: Option<Box<Node<'a>>>, pub pseudo_elements: Option<Vec<Box<Node<'a>>>>, pub imported_document: Option<Box<Node<'a>>>, pub distributed_nodes: Option<Vec<BackendNode<'a>>>, pub is_svg: Option<bool>, }
DOM interaction is implemented in terms of mirror objects that represent the actual DOM nodes. DOMNode is a base node mirror type.
Fields
node_id: NodeId
Node identifier that is passed into the rest of the DOM messages as the nodeId
. Backend will only push node with given id
once. It is aware of all requested nodes and will only fire DOM events for nodes known to the client.
parent_id: Option<NodeId>
[Experimental] The id of the parent node if any.
backend_node_id: BackendNodeId
[Experimental] The BackendNodeId for this node.
node_type: i32
Node
's nodeType.
node_name: Cow<'a, str>
Node
's nodeName.
local_name: Cow<'a, str>
Node
's localName.
node_value: Cow<'a, str>
Node
's nodeValue.
child_node_count: Option<i32>
Child count for Container
nodes.
children: Option<Vec<Box<Node<'a>>>>
Child nodes of this node when requested with children.
attributes: Option<Vec<Cow<'a, str>>>
Attributes of the Element
node in the form of flat array [name1, value1, name2, value2]
.
document_url: Option<Cow<'a, str>>
Document URL that Document
or FrameOwner
node points to.
base_url: Option<Cow<'a, str>>
[Experimental] Base URL that Document
or FrameOwner
node uses for URL completion.
public_id: Option<Cow<'a, str>>
DocumentType
's publicId.
system_id: Option<Cow<'a, str>>
DocumentType
's systemId.
internal_subset: Option<Cow<'a, str>>
DocumentType
's internalSubset.
xml_version: Option<Cow<'a, str>>
Document
's XML version in case of XML documents.
name: Option<Cow<'a, str>>
Attr
's name.
value: Option<Cow<'a, str>>
Attr
's value.
pseudo_type: Option<PseudoType>
Pseudo element type for this node.
shadow_root_type: Option<ShadowRootType>
Shadow root type.
frame_id: Option<FrameId<'a>>
[Experimental] Frame ID for frame owner elements.
content_document: Option<Box<Node<'a>>>
Content document for frame owner elements.
shadow_roots: Option<Vec<Box<Node<'a>>>>
[Experimental] Shadow root list for given element host.
template_content: Option<Box<Node<'a>>>
[Experimental] Content document fragment for template elements.
pseudo_elements: Option<Vec<Box<Node<'a>>>>
[Experimental] Pseudo elements associated with this node.
imported_document: Option<Box<Node<'a>>>
Import document for the HTMLImport links.
distributed_nodes: Option<Vec<BackendNode<'a>>>
[Experimental] Distributed nodes for given insertion point.
is_svg: Option<bool>
[Experimental] Whether the node is SVG.
Trait Implementations
impl<'a> Clone for Node<'a>
[src]
fn clone(&self) -> Node<'a>
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more