jsdIStackFrame 编辑

js/jsd/idl/jsdIDebuggerService.idlScriptable Please add a summary to this article. Inherits from: jsdIEphemeral Last changed in Gecko 2.0 (Firefox 4 / Thunderbird 3.3 / SeaMonkey 2.1)

Strict mode is on. Warnings reported as errors. Makes eval() use the last object on its 'obj' param's scope chain as the ECMA 'variables object'. Private data for this object is an nsISupports object. Attempting to alter this bit will result in an NS_ERROR_ILLEGAL_VALUE. OPT_* values above, OR'd together. Last version set on this context. Scripts typically select this with the "language" attribute. See the VERSION_* consts on jsdIDebuggerService. Unique tag among all valid jsdIContext objects, useful as a hash key. Private data for this context, if it is an nsISupports, |null| otherwise. Retrieve the underlying context wrapped by this jsdIContext. Top of the scope chain for this context. |true| if this context should be allowed to run scripts, |false| otherwise. This attribute is only valid for contexts which implement nsIScriptContext. Setting or getting this attribute on any other context will throw a NS_ERROR_NO_INTERFACE exception. Stack frame objects. These are only valid inside the jsdIExecutionHook which gave it to you. After you return from that handler the bottom frame, and any frame you found attached through it, are invalidated via the jsdIEphemeral interface. Once a jsdIStackFrame has been invalidated all method and property accesses will throw a NS_ERROR_NOT_AVAILABLE exception.

Method overview

boolean eval(in AString bytes, in AUTF8String fileName, in unsigned long line, out jsdIValue result);

Attributes

AttributeTypeDescription
calleejsdIValueFunction object running in this stack frame. Read only.
callingFramejsdIStackFrameLink to the caller's stack frame. Read only.
executionContextjsdIContextExecuton context. Read only.
functionNameAUTF8StringFunction name executing in this stack frame. Read only.
isConstructingbooleanTrue if stack frame is constructing a new object. Read only.
isDebuggerbooleanTrue if stack frame represents a frame created as a result of a debugger evaluation. Read only.
isNativebooleanTrue if stack frame represents a native frame. Read only. Obsolete since Gecko 2.0
JSDContextJSDContextInternal use only. Read only. Native code only!
JSDStackFrameInfoJSDStackFrameInfoInternal use only. Read only. Native code only!
JSDThreadStateJSDThreadStateInternal use only. Read only. Native code only!
lineunsigned longCurrent line number (using the script's pc to line map.) Read only.
pcunsigned longCurrent program counter in this stack frame. Read only.
scopejsdIValueTop object in the scope chain. Read only.
scriptjsdIScriptScript running in this stack frame, null for native frames. Read only.
thisValuejsdIValue|this| object for this stack frame. Read only.

Methods

eval()

Evaluate arbitrary JavaScript in this stack frame.

boolean eval(
  in AString bytes,
  in AUTF8String fileName,
  in unsigned long line,
  out jsdIValue result
);
Parameters
bytes
Script to be evaluated.
fileName
Filename to compile this script under. This is the filename you'll see in error messages, and so on.
line
result
Return value

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据

词条统计

浏览:113 次

字数:7186

最后编辑:6 年前

编辑次数:0 次

    我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
    原文