@mozilla.org/js/jsd/debugger-service;1

This component implements the following interfaces:

Constants

Possible values for jsdIScript::version and jsdIContext::version.
PRInt32 jsdIDebuggerService.VERSION_1_0 = 100
PRInt32 jsdIDebuggerService.VERSION_1_1 = 110
PRInt32 jsdIDebuggerService.VERSION_1_2 = 120
PRInt32 jsdIDebuggerService.VERSION_1_3 = 130
PRInt32 jsdIDebuggerService.VERSION_1_4 = 140
PRInt32 jsdIDebuggerService.VERSION_1_5 = 150
PRInt32 jsdIDebuggerService.VERSION_DEFAULT = 0
PRInt32 jsdIDebuggerService.VERSION_UNKNOWN = -1
Link native frames in call stacks.
PRUint32 jsdIDebuggerService.ENABLE_NATIVE_FRAMES = 1
Normally, if a script has a 0 in JSD_SCRIPT_PROFILE_BIT it is included in profile data, otherwise it is not profiled. Setting the PROFILE_WHEN_SET flag reverses this convention.
PRUint32 jsdIDebuggerService.PROFILE_WHEN_SET = 2
Normally, when the script in the top frame of a thread state has a 1 in JSD_SCRIPT_DEBUG_BIT, the execution hook is ignored. Setting the DEBUG_WHEN_SET flag reverses this convention.
PRUint32 jsdIDebuggerService.DEBUG_WHEN_SET = 4
When this flag is set the internal call hook will collect profile data.
PRUint32 jsdIDebuggerService.COLLECT_PROFILE_DATA = 8
When this flag is set, stack frames that are disabled for debugging will not appear in the call stack chain.
PRUint32 jsdIDebuggerService.HIDE_DISABLED_FRAMES = 16
When this flag is set, the debugger will only check the JSD_SCRIPT_DEBUG_BIT on the top (most recent) stack frame. This makes it possible to stop in an enabled frame which was called from a stack that contains a disabled frame.

When this flag is *not* set, any stack that contains a disabled frame will not be debugged (the execution hook will not be invoked.)

This only applies when the reason for calling the hook would have been TYPE_INTERRUPTED or TYPE_THROW. TYPE_BREAKPOINT, TYPE_DEBUG_REQUESTED, and TYPE_DEBUGGER_KEYWORD always stop, regardless of this setting, as long as the top frame is not disabled.

If HIDE_DISABLED_FRAMES is set, this is effectively set as well.

PRUint32 jsdIDebuggerService.MASK_TOP_FRAME_ONLY = 32
When this flag is set, object creation will not be tracked. This will reduce the performance price you pay by enabling the debugger.
PRUint32 jsdIDebuggerService.DISABLE_OBJECT_TRACE = 64

Properties

jsdIExecutionHook* jsdIDebuggerService.breakpointHook

Called when the engine encounters a breakpoint.

jsdIExecutionHook* jsdIDebuggerService.debuggerHook

Called when the engine encounters the debugger keyword.

jsdIExecutionHook* jsdIDebuggerService.debugHook

Called when the errorHook returns false.

jsdIErrorHook* jsdIDebuggerService.errorHook

Called when an error or warning occurs.

PRUint32 jsdIDebuggerService.flags

Debugger service flags.

jsdICallHook* jsdIDebuggerService.functionHook

Called before and after a function is called.

readonly PRUint32 jsdIDebuggerService.implementationMajor

Major version number of implementation.

readonly PRUint32 jsdIDebuggerService.implementationMinor

Minor version number of implementation.

readonly char* jsdIDebuggerService.implementationString

Free form string identifier for implementation.

PRBool jsdIDebuggerService.initAtStartup

True if the debugger should register an app-start observer in order to begin collecting debug information when mozilla is launched.

jsdIExecutionHook* jsdIDebuggerService.interruptHook

Called before the next PC is executed.

readonly PRBool jsdIDebuggerService.isOn

True if the debugger service has been turned on. This does not necessarily mean another app is actively using the service, as the autostart pref may have turned the service on.

readonly JSDContext* jsdIDebuggerService.JSDContext

readonly PRUint32 jsdIDebuggerService.pauseDepth

Peek at the current pause depth of the debugger.

jsdIScriptHook* jsdIDebuggerService.scriptHook

Called when a jsdIScript is created or destroyed.

jsdIExecutionHook* jsdIDebuggerService.throwHook

Called when an exception is thrown (even if it will be caught.)

jsdICallHook* jsdIDebuggerService.topLevelHook

Called before and after a toplevel script is evaluated.

Methods

InterfaceMethod
jsdIDebuggerService void appendFilter ( jsdIFilter* filter )
jsdIDebuggerService void clearAllBreakpoints ( )
jsdIDebuggerService void clearFilters ( )
jsdIDebuggerService void clearProfileData ( )
jsdIDebuggerService PRUint32 enterNestedEventLoop ( jsdINestCallback* callback )
jsdIDebuggerService void enumerateContexts ( jsdIContextEnumerator* enumerator )
jsdIDebuggerService void enumerateFilters ( jsdIFilterEnumerator* enumerator )
jsdIDebuggerService void enumerateScripts ( jsdIScriptEnumerator* enumerator )
jsdIDebuggerService PRUint32 exitNestedEventLoop ( )
jsdIDebuggerService void GC ( )
jsdIDebuggerService void insertFilter ( jsdIFilter* filter , jsdIFilter* after )
jsdIDebuggerService void off ( )
jsdIDebuggerService void on ( )
jsdIDebuggerService [noscript] void onForRuntime ( JSRuntime* rt )
jsdIDebuggerService PRUint32 pause ( )
jsdIDebuggerService void refreshFilters ( )
jsdIDebuggerService void removeFilter ( jsdIFilter* filter )
jsdIDebuggerService void swapFilters ( jsdIFilter* filter_a , jsdIFilter* filter_b )
jsdIDebuggerService PRUint32 unPause ( )
jsdIDebuggerService jsdIValue* wrapValue ( )

Reference documentation is generated from Mozilla's source.

Add a note User Contributed Notes
No comments available

Copyright © 1999 - 2005 XULPlanet.com