DOMDebugger

class DOMDebugger(cdp: CDP) : Domain

DOM debugging allows setting breakpoints on particular DOM operations and events. JavaScript execution will stop on these operations as if there was a regular breakpoint set.

Constructors

Link copied to clipboard
constructor(cdp: CDP)

Types

Link copied to clipboard

CSP Violation type.

Link copied to clipboard

DOM breakpoint type.

Link copied to clipboard
@Serializable
data class EventListener(val type: String, val useCapture: Boolean, val passive: Boolean, val once: Boolean, val scriptId: String, val lineNumber: Int, val columnNumber: Int, val handler: Runtime.RemoteObject? = null, val originalHandler: Runtime.RemoteObject? = null, val backendNodeId: Int? = null)

Object event listener.

Link copied to clipboard
@Serializable
data class GetEventListenersParameter(val objectId: String, val depth: Int? = null, val pierce: Boolean? = null)
Link copied to clipboard
@Serializable
data class GetEventListenersReturn(val listeners: List<DOMDebugger.EventListener>)
Link copied to clipboard
@Serializable
data class RemoveDOMBreakpointParameter(val nodeId: Int, val type: DOMDebugger.DOMBreakpointType)
Link copied to clipboard
@Serializable
data class RemoveEventListenerBreakpointParameter(val eventName: String, val targetName: String? = null)
Link copied to clipboard
@Serializable
data class RemoveInstrumentationBreakpointParameter(val eventName: String)
Link copied to clipboard
@Serializable
data class RemoveXHRBreakpointParameter(val url: String)
Link copied to clipboard
@Serializable
data class SetBreakOnCSPViolationParameter(val violationTypes: List<DOMDebugger.CSPViolationType>)
Link copied to clipboard
@Serializable
data class SetDOMBreakpointParameter(val nodeId: Int, val type: DOMDebugger.DOMBreakpointType)
Link copied to clipboard
@Serializable
data class SetEventListenerBreakpointParameter(val eventName: String, val targetName: String? = null)
Link copied to clipboard
@Serializable
data class SetInstrumentationBreakpointParameter(val eventName: String)
Link copied to clipboard
@Serializable
data class SetXHRBreakpointParameter(val url: String)

Functions

Link copied to clipboard
suspend fun getEventListeners(objectId: String, depth: Int? = null, pierce: Boolean? = null): DOMDebugger.GetEventListenersReturn

Returns event listeners of the given object.

Link copied to clipboard
suspend fun removeDOMBreakpoint(args: DOMDebugger.RemoveDOMBreakpointParameter, mode: CommandMode = CommandMode.DEFAULT)

Removes DOM breakpoint that was set using setDOMBreakpoint.

Link copied to clipboard
suspend fun removeEventListenerBreakpoint(eventName: String, targetName: String? = null)

Removes breakpoint on particular DOM event.

Link copied to clipboard
suspend fun removeInstrumentationBreakpoint(eventName: String)

Removes breakpoint on particular native event.

Link copied to clipboard
suspend fun removeXHRBreakpoint(url: String)
suspend fun removeXHRBreakpoint(args: DOMDebugger.RemoveXHRBreakpointParameter, mode: CommandMode = CommandMode.DEFAULT)

Removes breakpoint from XMLHttpRequest.

Link copied to clipboard

Sets breakpoint on particular CSP violations.

Link copied to clipboard
suspend fun setDOMBreakpoint(args: DOMDebugger.SetDOMBreakpointParameter, mode: CommandMode = CommandMode.DEFAULT)

Sets breakpoint on particular operation with DOM.

Link copied to clipboard
suspend fun setEventListenerBreakpoint(eventName: String, targetName: String? = null)

Sets breakpoint on particular DOM event.

Link copied to clipboard
suspend fun setInstrumentationBreakpoint(eventName: String)

Sets breakpoint on particular native event.

Link copied to clipboard
suspend fun setXHRBreakpoint(url: String)
suspend fun setXHRBreakpoint(args: DOMDebugger.SetXHRBreakpointParameter, mode: CommandMode = CommandMode.DEFAULT)

Sets breakpoint on XMLHttpRequest.