| OLD | NEW |
| 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 |
| 21 /** |
| 22 * Sets a breakpoint at line \line_number in \script_url, or the closest |
| 23 * following line (within the same function) where a breakpoint can be set. |
| 24 * |
| 25 * Requires there to be a current isolate. |
| 26 * |
| 27 * \breakpoint If non-null, will point to the breakpoint object |
| 28 * if a breakpoint was successfully created. |
| 29 * |
| 30 * \return A handle to the True object if no error occurs. |
| 31 */ |
| 32 DART_EXPORT Dart_Handle Dart_SetBreakpointAtLine( |
| 33 Dart_Handle script_url, |
| 34 Dart_Handle line_number, |
| 35 Dart_Breakpoint* breakpoint); |
| 36 |
| 37 |
| 20 /** | 38 /** |
| 21 * Sets a breakpoint at the entry of the given function. If class_name | 39 * Sets a breakpoint at the entry of the given function. If class_name |
| 22 * is the empty string, looks for a library function with the given | 40 * is the empty string, looks for a library function with the given |
| 23 * name. | 41 * name. |
| 24 * | 42 * |
| 25 * Requires there to be a current isolate. | 43 * Requires there to be a current isolate. |
| 26 * | 44 * |
| 27 * \breakpoint If non-null, will point to the breakpoint object | 45 * \breakpoint If non-null, will point to the breakpoint object |
| 28 * if a breakpoint was successfully created. | 46 * if a breakpoint was successfully created. |
| 29 * | 47 * |
| 30 * \return A handle to the True object if no error occurs. | 48 * \return A handle to the True object if no error occurs. |
| 31 */ | 49 */ |
| 32 DART_EXPORT Dart_Handle Dart_SetBreakpointAtEntry( | 50 DART_EXPORT Dart_Handle Dart_SetBreakpointAtEntry( |
| 33 Dart_Handle library, | 51 Dart_Handle library, |
| 34 Dart_Handle class_name, | 52 Dart_Handle class_name, |
| 35 Dart_Handle function_name, | 53 Dart_Handle function_name, |
| 36 Dart_Breakpoint* breakpoint); | 54 Dart_Breakpoint* breakpoint); |
| 37 | 55 |
| 56 |
| 38 /** | 57 /** |
| 39 * Installs a handler callback function that gets called by the VM | 58 * Installs a handler callback function that gets called by the VM |
| 40 * when a breakpoint has been reached. | 59 * when a breakpoint has been reached. |
| 41 * | 60 * |
| 42 * Requires there to be a current isolate. | 61 * Requires there to be a current isolate. |
| 43 */ | 62 */ |
| 44 DART_EXPORT void Dart_SetBreakpointHandler( | 63 DART_EXPORT void Dart_SetBreakpointHandler( |
| 45 Dart_BreakpointHandler bp_handler); | 64 Dart_BreakpointHandler bp_handler); |
| 46 | 65 |
| 47 | 66 |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 87 * \return A handle to the True object if no error occurs. | 106 * \return A handle to the True object if no error occurs. |
| 88 */ | 107 */ |
| 89 DART_EXPORT Dart_Handle Dart_ActivationFrameInfo( | 108 DART_EXPORT Dart_Handle Dart_ActivationFrameInfo( |
| 90 Dart_ActivationFrame activation_frame, | 109 Dart_ActivationFrame activation_frame, |
| 91 Dart_Handle* function_name, | 110 Dart_Handle* function_name, |
| 92 Dart_Handle* script_url, | 111 Dart_Handle* script_url, |
| 93 intptr_t* line_number); | 112 intptr_t* line_number); |
| 94 | 113 |
| 95 | 114 |
| 96 #endif // INCLUDE_DART_DEBUGGER_API_H_ | 115 #endif // INCLUDE_DART_DEBUGGER_API_H_ |
| OLD | NEW |