Expand description
Runtime domain exposes JavaScript runtime by means of remote evaluation and mirror objects. Evaluation results are returned as mirror object that expose object type, string representation and unique identifier that can be used for further object reference. Original objects are maintained in memory unless they are either explicitly released or are released along with the other objects in their object group.
Types, command parameters and event payloads for the Runtime
domain. The method-name constants for the same domain are in
crate::methods.
Structs§
- AddBinding
Params - If executionContextId is empty, adds binding with the given name on the global objects of all inspected contexts, including those created later, bindings survive reloads. Binding function takes exactly one argument, this argument should be string, in case of any other input, function throws an exception. Each binding function call produces Runtime.bindingCalled notification.
- Await
Promise Params - Add handler to promise with given promise object id.
- Await
Promise Returns - What
Runtime.awaitPromiseanswers with. - Binding
Called Event - Notification is issued every time when binding is called.
- Call
Argument - Represents function call argument. Either remote object id
objectId, primitivevalue, unserializable primitive value or neither of (for undefined) them should be specified. - Call
Frame - Stack entry for runtime errors and assertions.
- Call
Function OnParams - Calls function with given declaration on the given object. Object group of the result is inherited from the target object.
- Call
Function OnReturns - What
Runtime.callFunctionOnanswers with. - Compile
Script Params - Compiles expression.
- Compile
Script Returns - What
Runtime.compileScriptanswers with. - Console
ApiCalled Event - Issued when console API was called.
- Custom
Preview - Experimental: may change without notice.
- Deep
Serialized Value - Represents deep serialized value.
- Disable
Params - Disables reporting of execution contexts creation.
- Discard
Console Entries Params - Discards collected exceptions and console API calls.
- Enable
Params - Enables reporting of execution contexts creation by means of
executionContextCreatedevent. When the reporting gets enabled the event will be sent immediately for each existing execution context. - Entry
Preview - Experimental: may change without notice.
- Evaluate
Params - Evaluates expression on global object.
- Evaluate
Returns - What
Runtime.evaluateanswers with. - Exception
Details - Detailed information about exception (or error) that was thrown during script compilation or execution.
- Exception
Revoked Event - Issued when unhandled exception was revoked.
- Exception
Thrown Event - Issued when exception was thrown and unhandled.
- Execution
Context Created Event - Issued when new execution context is created.
- Execution
Context Description - Description of an isolated world.
- Execution
Context Destroyed Event - Issued when execution context is destroyed.
- Execution
Contexts Cleared Event - Issued when all executionContexts were cleared in browser
- GetException
Details Params - This method tries to lookup and populate exception details for a JavaScript Error object. Note that the stackTrace portion of the resulting exceptionDetails will only be populated if the Runtime domain was enabled at the time when the Error was thrown.
- GetException
Details Returns - What
Runtime.getExceptionDetailsanswers with. - GetHeap
Usage Params - Returns the JavaScript heap usage. It is the total usage of the corresponding isolate not scoped to a particular Runtime.
- GetHeap
Usage Returns - What
Runtime.getHeapUsageanswers with. - GetIsolate
IdParams - Returns the isolate id.
- GetIsolate
IdReturns - What
Runtime.getIsolateIdanswers with. - GetProperties
Params - Returns properties of a given object. Object group of the result is inherited from the target object.
- GetProperties
Returns - What
Runtime.getPropertiesanswers with. - Global
Lexical Scope Names Params - Returns all let, const and class variables from global scope.
- Global
Lexical Scope Names Returns - What
Runtime.globalLexicalScopeNamesanswers with. - Inspect
Requested Event - Issued when object should be inspected (for example, as a result of inspect() command line API call).
- Internal
Property Descriptor - Object internal property descriptor. This property isn’t normally visible in JavaScript code.
- Object
Preview - Object containing abbreviated remote object value.
- Private
Property Descriptor - Object private field descriptor.
- Property
Descriptor - Object property descriptor.
- Property
Preview - Experimental: may change without notice.
- Query
Objects Params - Parameters of
Runtime.queryObjects. - Query
Objects Returns - What
Runtime.queryObjectsanswers with. - Release
Object Group Params - Releases all remote objects that belong to a given group.
- Release
Object Params - Releases remote object with given id.
- Remote
Object - Mirror object referencing original JavaScript object.
- Remove
Binding Params - This method does not remove binding function from global object but unsubscribes current runtime agent from Runtime.bindingCalled notifications.
- RunIf
Waiting ForDebugger Params - Tells inspected instance to run if it was waiting for debugger to attach.
- RunScript
Params - Runs script with given id in a given context.
- RunScript
Returns - What
Runtime.runScriptanswers with. - Serialization
Options - Represents options for serialization. Overrides
generatePreviewandreturnByValue. - SetAsync
Call Stack Depth Params - Enables or disables async call stacks tracking.
- SetCustom
Object Formatter Enabled Params - Experimental: may change without notice.
- SetMax
Call Stack Size ToCapture Params - Experimental: may change without notice.
- Stack
Trace - Call frames for assertions or error messages.
- Stack
Trace Id - If
debuggerIdis set stack trace comes from another debugger and can be resolved there. This allows to track cross-debugger calls. SeeRuntime.StackTraceandDebugger.pausedfor usages. - Terminate
Execution Params - Terminate current or next JavaScript execution. Will cancel the termination when the outer-most script execution ends.
Enums§
- Console
ApiCalled Type - The values
typeaccepts onconsoleAPICalled. - Deep
Serialized Value Type - The values
typeaccepts onDeepSerializedValue. - Object
Preview Subtype - The values
subtypeaccepts onObjectPreview. - Object
Preview Type - The values
typeaccepts onObjectPreview. - Property
Preview Subtype - The values
subtypeaccepts onPropertyPreview. - Property
Preview Type - The values
typeaccepts onPropertyPreview. - Remote
Object Subtype - The values
subtypeaccepts onRemoteObject. - Remote
Object Type - The values
typeaccepts onRemoteObject. - Serialization
Options Serialization - The values
serializationaccepts onSerializationOptions.
Type Aliases§
- Execution
Context Id - Id of an execution context.
- Remote
Object Id - Unique object identifier.
- Script
Id - Unique script identifier.
- Time
Delta - Number of milliseconds.
- Timestamp
- Number of milliseconds since epoch.
- Unique
Debugger Id - Unique identifier of current debugger.
- Unserializable
Value - Primitive value which cannot be JSON-stringified. Includes values
-0,NaN,Infinity,-Infinity, and bigint literals.