JsDebugScope Class

A scope of a frame paused by a debugger (JsDebugFrame.GetScopes): its variables, or its binding object.

public sealed class JsDebugScope

Properties

NameDescription
BindingObjectGets the object whose properties are the variables of the scope: the global object, or the object of a with statement. Null for the other scopes.
KindGets the kind of the scope.
VariablesGets the variables of the scope, in the order of their declarations. The variables of the JsDebugScopeKind.Global and JsDebugScopeKind.With scopes are the properties of their JsDebugScope.BindingObject.

BindingObject

JsDebugScope.cs

Gets the object whose properties are the variables of the scope: the global object, or the object of a with statement. Null for the other scopes.

public JsObject? BindingObject { get; }

Property value

JsObject?

Gets the kind of the scope.

public JsDebugScopeKind Kind { get; }

Property value

JsDebugScopeKind

Gets the variables of the scope, in the order of their declarations. The variables of the JsDebugScopeKind.Global and JsDebugScopeKind.With scopes are the properties of their JsDebugScope.BindingObject.

public IReadOnlyList<JsDebugVariable> Variables { get; }

Methods

NameDescription
TryGetVariable(string, JsDebugVariable)Gets the variable of the scope that has a name.

TryGetVariable(string, JsDebugVariable)

JsDebugScope.cs

Gets the variable of the scope that has a name.

public bool TryGetVariable(string name, out JsDebugVariable variable)

Parameters

name string
The name of the variable.
variable JsDebugVariable
The variable, when it is found.

Returns

bool True when the scope has a variable of this name in JsDebugScope.Variables.