Click or drag to resize

DOMClient Class

Version 86.0.240
This domain exposes DOM read/write operations. Each DOM Node is represented with its mirror object that has an `id`. This `id` can be used to get additional information on the Node, resolve it into the JavaScript object wrapper, etc. It is important that client receives DOM events only for the nodes that are known to the client. Backend keeps track of the nodes that were sent to the client and never sends the same node twice. It is client's responsibility to collect information about the nodes that were sent to the client.

Note that `iframe` owner elements will return corresponding document elements as their child nodes.

Inheritance Hierarchy

Namespace:  CefSharp.DevTools.DOM
Assembly:  CefSharp (in CefSharp.dll) Version: 86.0.240.0 (86.0.240.0)
Syntax
public class DOMClient : DevToolsDomainBase

The DOMClient type exposes the following members.

Constructors
  NameDescription
Public methodDOMClient
Initializes a new instance of the DOMClient class
Top
Methods
  NameDescription
Public methodCollectClassNamesFromSubtreeAsync
Collects class names for the node with given id and all of it's child nodes.
Public methodCopyToAsync
Public methodDescribeNodeAsync
Public methodDisableAsync
Disables DOM agent for the given page.
Public methodDiscardSearchResultsAsync
Discards search results from the session with the given id. `getSearchResults` should no longer be called for that search.
Public methodEnableAsync
Enables DOM agent for the given page.
Protected methodEnumToString(Enum) (Inherited from DevToolsDomainBase.)
Protected methodEnumToString(PermissionType) (Inherited from DevToolsDomainBase.)
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodFocusAsync
Focuses the given element.
Public methodGetAttributesAsync
Returns attributes for the specified node.
Public methodGetBoxModelAsync
Returns boxes for the given node.
Public methodGetContentQuadsAsync
Returns quads that describe node position on the page. This method might return multiple quads for inline nodes.
Public methodGetDocumentAsync
Public methodGetFileInfoAsync
Returns file information for the given File wrapper.
Public methodGetFrameOwnerAsync
Returns iframe node that owns iframe with the given domain.
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetNodeForLocationAsync
Returns node id at given location. Depending on whether DOM domain is enabled, nodeId is either returned or not.
Public methodGetNodesForSubtreeByStyleAsync
Public methodGetNodeStackTracesAsync
Gets stack traces associated with a Node. As of now, only provides stack trace for Node creation.
Public methodGetOuterHTMLAsync
Returns node's HTML markup.
Public methodGetRelayoutBoundaryAsync
Returns the id of the nearest ancestor that is a relayout boundary.
Public methodGetSearchResultsAsync
Returns search results from given `fromIndex` to given `toIndex` from the search with the given identifier.
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodHideHighlightAsync
Hides any highlight.
Public methodHighlightNodeAsync
Highlights DOM node.
Public methodHighlightRectAsync
Highlights given rectangle.
Public methodMarkUndoableStateAsync
Marks last undoable state.
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodMoveToAsync
Public methodPerformSearchAsync
Searches for a given string in the DOM tree. Use `getSearchResults` to access search results or `cancelSearch` to end this search session.
Public methodPushNodeByPathToFrontendAsync
Requests that the node is sent to the caller given its path. // FIXME, use XPath
Public methodPushNodesByBackendIdsToFrontendAsync
Requests that a batch of nodes is sent to the caller given their backend node ids.
Public methodQuerySelectorAllAsync
Executes `querySelectorAll` on a given node.
Public methodQuerySelectorAsync
Executes `querySelector` on a given node.
Public methodRedoAsync
Re-does the last undone action.
Public methodRemoveAttributeAsync
Removes attribute with given name from an element with given id.
Public methodRemoveNodeAsync
Removes node with given id.
Public methodRequestChildNodesAsync
Public methodRequestNodeAsync
Requests that the node is sent to the caller given the JavaScript node object reference. All nodes that form the path from the node to the root are also sent to the client as a series of `setChildNodes` notifications.
Public methodResolveNodeAsync
Resolves the JavaScript node object for a given NodeId or BackendNodeId.
Public methodScrollIntoViewIfNeededAsync
Public methodSetAttributesAsTextAsync
Public methodSetAttributeValueAsync
Sets attribute for an element with given id.
Public methodSetFileInputFilesAsync
Sets files for the given file input element.
Public methodSetInspectedNodeAsync
Enables console to refer to the node with given id via $x (see Command Line API for more details $x functions).
Public methodSetNodeNameAsync
Sets node name for a node with given id.
Public methodSetNodeStackTracesEnabledAsync
Sets if stack traces should be captured for Nodes. See `Node.getNodeStackTraces`. Default is disabled.
Public methodSetNodeValueAsync
Sets node value for a node with given id.
Public methodSetOuterHTMLAsync
Sets node HTML markup, returns new node id.
Protected methodToBase64String (Inherited from DevToolsDomainBase.)
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Public methodUndoAsync
Undoes the last performed action.
Top
See Also