Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(117)

Side by Side Diff: include/dart_debugger_api.h

Issue 11026011: Add isolate event handler setup in order to be able to propagate isolate (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: Created 8 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « bin/main.cc ('k') | vm/code_generator.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #ifndef INCLUDE_DART_DEBUGGER_API_H_ 5 #ifndef INCLUDE_DART_DEBUGGER_API_H_
6 #define INCLUDE_DART_DEBUGGER_API_H_ 6 #define INCLUDE_DART_DEBUGGER_API_H_
7 7
8 #include "include/dart_api.h" 8 #include "include/dart_api.h"
9 9
10 typedef struct _Dart_Breakpoint* Dart_Breakpoint; 10 typedef struct _Dart_Breakpoint* Dart_Breakpoint;
11 11
12 typedef struct _Dart_StackTrace* Dart_StackTrace; 12 typedef struct _Dart_StackTrace* Dart_StackTrace;
13 13
14 typedef struct _Dart_ActivationFrame* Dart_ActivationFrame; 14 typedef struct _Dart_ActivationFrame* Dart_ActivationFrame;
15 15
16 typedef void Dart_BreakpointHandler( 16 typedef void Dart_BreakpointHandler(
17 Dart_Breakpoint breakpoint, 17 Dart_Breakpoint breakpoint,
18 Dart_StackTrace stack_trace); 18 Dart_StackTrace stack_trace);
19 19
20 typedef void Dart_BreakpointResolvedHandler( 20 typedef void Dart_BreakpointResolvedHandler(
21 intptr_t bp_id, 21 intptr_t bp_id,
22 Dart_Handle url, 22 Dart_Handle url,
23 intptr_t line_number); 23 intptr_t line_number);
24 24
25 typedef void Dart_ExceptionThrownHandler( 25 typedef void Dart_ExceptionThrownHandler(
26 Dart_Handle exception_object, 26 Dart_Handle exception_object,
27 Dart_StackTrace stack_trace); 27 Dart_StackTrace stack_trace);
28 28
29 typedef enum {
30 kCreated = 0,
31 kInterrupted,
32 kShutdown,
33 } Dart_IsolateEvent;
34
35 typedef void Dart_IsolateEventHandler(Dart_Isolate isolate,
36 Dart_IsolateEvent kind);
29 37
30 /** 38 /**
31 * Caches a given \object and returns an object id. The object id is only 39 * Caches a given \object and returns an object id. The object id is only
32 * valid while the VM is paused. The cache is invalidated when the VM 40 * valid while the VM is paused. The cache is invalidated when the VM
33 * resumes. 41 * resumes.
34 * 42 *
35 * Requires there to be a current isolate. 43 * Requires there to be a current isolate.
36 * 44 *
37 * Returns an id >= 0 on success, or -1 if there is an error. 45 * Returns an id >= 0 on success, or -1 if there is an error.
38 */ 46 */
(...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after
280 288
281 /** 289 /**
282 * Installs a callback function that gets called by the VM when 290 * Installs a callback function that gets called by the VM when
283 * an exception has been thrown. 291 * an exception has been thrown.
284 * 292 *
285 * Requires there to be a current isolate. 293 * Requires there to be a current isolate.
286 */ 294 */
287 DART_EXPORT void Dart_SetExceptionThrownHandler( 295 DART_EXPORT void Dart_SetExceptionThrownHandler(
288 Dart_ExceptionThrownHandler handler); 296 Dart_ExceptionThrownHandler handler);
289 297
298 /**
299 * Installs a callback function that gets called by the VM when
300 * an isolate event happens, e.g:
301 * - creation of a new isolate
302 * - shutdown of an isolate
303 * - interruption of an isolate
304 */
305 DART_EXPORT void Dart_SetIsolateEventHandler(Dart_IsolateEventHandler handler);
290 306
291 // On which exceptions to pause. 307 // On which exceptions to pause.
292 typedef enum { 308 typedef enum {
293 kNoPauseOnExceptions = 1, 309 kNoPauseOnExceptions = 1,
294 kPauseOnUnhandledExceptions, 310 kPauseOnUnhandledExceptions,
295 kPauseOnAllExceptions, 311 kPauseOnAllExceptions,
296 } Dart_ExceptionPauseInfo; 312 } Dart_ExceptionPauseInfo;
297 313
298 /** 314 /**
299 * Define on which exceptions the debugger pauses. 315 * Define on which exceptions the debugger pauses.
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after
521 * Returns the url of the library \library_id. 537 * Returns the url of the library \library_id.
522 * 538 *
523 * Requires there to be a current isolate. 539 * Requires there to be a current isolate.
524 * 540 *
525 * \return A string handle containing the URL of the library. 541 * \return A string handle containing the URL of the library.
526 */ 542 */
527 DART_EXPORT Dart_Handle Dart_GetLibraryURL(intptr_t library_id); 543 DART_EXPORT Dart_Handle Dart_GetLibraryURL(intptr_t library_id);
528 544
529 545
530 #endif // INCLUDE_DART_DEBUGGER_API_H_ 546 #endif // INCLUDE_DART_DEBUGGER_API_H_
OLDNEW
« no previous file with comments | « bin/main.cc ('k') | vm/code_generator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698