Revision: 6223
Author: [email protected]
Date: Fri Jan 7 04:34:38 2011
Log: Edited wiki page DebuggerProtocol through web user interface.
http://code.google.com/p/v8/source/detail?r=6223
Modified:
/wiki/DebuggerProtocol.wiki
=======================================
--- /wiki/DebuggerProtocol.wiki Wed Dec 15 13:22:17 2010
+++ /wiki/DebuggerProtocol.wiki Fri Jan 7 04:34:38 2011
@@ -361,6 +361,9 @@
(default is 4 for normal scripts)>
"ids" : <array of id's of scripts to return.
If this is not specified all scripts are requrned>
"includeSource" : <boolean indicating whether the source
code should be included for the scripts returned>
+ "filter" : <string or number: filter string or
script id.
+ If a number is specified, then only
the script with the number as its script id will be retrieved.
+ If a string is specified, then only
scripts whose names contain the filter string will be retrieved.>
}
}
}}}
@@ -536,6 +539,74 @@
{"seq":117,"type":"request","command":"clearbreakpoint","arguments":{"type":"function,"breakpoint":1}}
{"seq":118,"type":"request","command":"clearbreakpoint","arguments":{"type":"script","breakpoint":2}}
}}}
+
+== Request `setexceptionbreak`==
+
+The request `setexceptionbreak` is a request to enable/disable breaks on
all / uncaught exceptions. If the "enabled" argument is not specify, the
debuggee will toggle the state of the specified break type.
+
+{{{
+{ "seq" : <number>,
+ "type" : "request",
+ "command" : "setexceptionbreak",
+ "arguments" : { "type" : <string: "all", or "uncaught">,
+ "enabled" : <optional bool: enables the break type if
true>
+ }
+}
+}}}
+
+In response, the break on exception property of the debuggee will be set
accordingly, and the following response message will be dispatched to the
debugger.
+
+{{{
+{ "seq" : <number>,
+ "type" : "response",
+ "request_seq" : <number>,
+ "command" : "setexceptionbreak",
+ “body” : { "type" : <string: "all" or "uncaught" corresponding
to the request.>,
+ "enabled" : <bool: true if the break type is currently
enabled as a result of the request>
+ }
+ "running" : true
+ "success" : true
+}
+}}}
+
+Here are a few examples.
+
+{{{
+{"seq":117,"type":"request","command":"setexceptionbreak","arguments":{"type":"all"}}
+{"seq":118,"type":"request","command":"
setexceptionbreak","arguments":{"type":"all",”enabled”:false}}
+{"seq":119,"type":"request","command":"
setexceptionbreak","arguments":{"type":"uncaught","enabled":true}}
+}}}
+
+== Request `v8flags` ==
+The request v8flags is a request to apply the specified v8 flags
(analogous to how they are specified on the command line).
+
+{{{
+{ "seq" : <number>,
+ "type" : "request",
+ "command" : "v8flags",
+ "arguments" : { "flags" : <string: a sequence of v8 flags just like
those used on the command line>
+ }
+}
+}}}
+
+In response, the specified flags will be applied in the debuggee if they
are legal flags. Their effects vary depending on the implementation of the
flag.
+
+{{{
+{ "seq" : <number>,
+ "type" : "response",
+ "request_seq" : <number>,
+ "command" : "v8flags",
+ "running" : true
+ "success" : true
+}
+}}}
+
+Here are a few examples.
+
+{{{
+{"seq":117,"type":"request","command":"v8flags","arguments":{"flags":"--trace_gc
—always_compact"}}
+{"seq":118,"type":"request","command":"
v8flags","arguments":{"flags":"--notrace_gc"}}
+}}}
== Request `version` =
@@ -581,6 +652,103 @@
"modules" : <profiler modules to resume or pause> }
}
}}}
+
+== Request `disconnect` ==
+
+The request `disconnect` is used to detach the remote debugger from the
debuggee. This will trigger the debuggee to disable all active breakpoints
and resumes execution if the debuggee was previously stopped at a break.
+
+{{{
+{ "seq" : <number>,
+ "type" : "request",
+ "command" : "disconnect",
+}
+}}}
+
+The only response for the `disconnect` request is the response to a
connect request if the debugger is still able to get a response before the
debuggee successfully disconnects.
+
+Here is an examples:
+
+{{{
+{"seq":117,"type":"request","command":"disconnect"}
+}}}
+
+== Request `gc` ==
+The request `gc` is a request to run the garbage collector in the debuggee.
+
+{{{
+{ "seq" : <number>,
+ "type" : "request",
+ "command" : "gc",
+ "arguments" : { "type" : <string: "all">,
+ }
+}
+}}}
+
+In response, the debuggee will run the specified GC type and send the
following response message:
+
+{{{
+{ "seq" : <number>,
+ "type" : "response",
+ "request_seq" : <number>,
+ "command" : "gc",
+ “body” : { "before" : <int: total heap usage in bytes before the
GC>,
+ "after" : <int: total heap usage in bytes after the
GC>
+ }
+ "running" : true
+ "success" : true
+}
+}}}
+
+Here is an example.
+
+{{{
+{"seq":117,"type":"request","command":"gc","arguments":{"type":"all"}}
+}}}
+
+== Request `listbreakpoints` ==
+
+The request `listbreakpoints` is used to get information on breakpoints
that may have been set by the debugger.
+
+{{{
+{ "seq" : <number>,
+ "type" : "request",
+ "command" : "listbreakpoints",
+}
+}}}
+
+Response:
+
+{{{
+{ "seq" : <number>,
+ "type" : "response",
+ "request_seq" : <number>,
+ "command" : "listbreakpoints",
+ "body" : { "breakpoints": [ { "type" :
<string: "scriptId" or "scriptName".>,
+ "script_id" : <int: script
id. Only defined if type is scriptId.>,
+ "script_name" : <string:
script name. Only defined if type is scriptName.>,
+ "number" : <int:
breakpoint number. Starts from 1.>,
+ "line" : <int: line
number of this breakpoint. Starts from 0.>,
+ "column" : <int: column
number of this breakpoint. Starts from 0.>,
+ "groupId" : <int: group id
of this breakpoint.>,
+ "hit_count" : <int: number
of times this breakpoint has been hit. Starts from 0.>,
+ "active" : <bool: true if
this breakpoint is enabled.>,
+ "ignoreCount" : <int:
remaining number of times to ignore breakpoint. Starts from 0.>,
+ "actual_locations" : <actual
locations of the breakpoint.>,
+ }
+ ],
+ "breakOnExceptions" : <true is break on all
exceptions is enabled>,
+ "breakOnUncaughtExceptions" : <true is break on
uncaught exceptions is enabled>
+ }
+ "running" : <is the VM running after sending this response>
+ "success" : true
+}
+}}}
+
+Here is an examples:
+
+{{{
+{"seq":117,"type":"request","command":"listbreakpoints"}
+}}}
= Events =
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev