| 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; |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 61 | 61 |
| 62 /** | 62 /** |
| 63 * Returns a cached object given the \obj_id. | 63 * Returns a cached object given the \obj_id. |
| 64 * | 64 * |
| 65 * Requires there to be a current isolate. | 65 * Requires there to be a current isolate. |
| 66 */ | 66 */ |
| 67 DART_EXPORT Dart_Handle Dart_GetCachedObject(intptr_t obj_id); | 67 DART_EXPORT Dart_Handle Dart_GetCachedObject(intptr_t obj_id); |
| 68 | 68 |
| 69 | 69 |
| 70 /** | 70 /** |
| 71 * DEPRECATED -- use Dart_GetLibraryIds instead. | |
| 72 * | |
| 73 * Returns a list of urls (strings) of all the libraries loaded in the | |
| 74 * current isolate. | |
| 75 * | |
| 76 * Requires there to be a current isolate. | |
| 77 * | |
| 78 * \return A handle to a list of string handles. | |
| 79 */ | |
| 80 DART_EXPORT Dart_Handle Dart_GetLibraryURLs(); | |
| 81 // TODO(turnidge): The embedding and debugger apis are not consistent | |
| 82 // in how they capitalize url. One uses 'Url' and the other 'URL'. | |
| 83 // They should be the same. | |
| 84 | |
| 85 | |
| 86 /** | |
| 87 * Returns a list of ids (integers) of all the libraries loaded in the | 71 * Returns a list of ids (integers) of all the libraries loaded in the |
| 88 * current isolate. | 72 * current isolate. |
| 89 * | 73 * |
| 90 * Requires there to be a current isolate. | 74 * Requires there to be a current isolate. |
| 91 * | 75 * |
| 92 * \return A handle to a list of library ids. | 76 * \return A handle to a list of library ids. |
| 93 */ | 77 */ |
| 94 DART_EXPORT Dart_Handle Dart_GetLibraryIds(); | 78 DART_EXPORT Dart_Handle Dart_GetLibraryIds(); |
| 95 | 79 |
| 96 | 80 |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 216 * | 200 * |
| 217 * Requires there to be a current isolate. | 201 * Requires there to be a current isolate. |
| 218 * | 202 * |
| 219 * \return A handle to the line number (integer) of the script, | 203 * \return A handle to the line number (integer) of the script, |
| 220 * or an error object. | 204 * or an error object. |
| 221 */ | 205 */ |
| 222 DART_EXPORT Dart_Handle Dart_GetBreakpointLine(intptr_t bp_id); | 206 DART_EXPORT Dart_Handle Dart_GetBreakpointLine(intptr_t bp_id); |
| 223 | 207 |
| 224 | 208 |
| 225 /** | 209 /** |
| 226 * DEPRECATED -- use Dart_SetBreakpoint instead. | |
| 227 * | |
| 228 * Sets a breakpoint at line \line_number in \script_url, or the closest | |
| 229 * following line (within the same function) where a breakpoint can be set. | |
| 230 * | |
| 231 * Requires there to be a current isolate. | |
| 232 * | |
| 233 * \breakpoint If non-null, will point to the breakpoint object | |
| 234 * if a breakpoint was successfully created. | |
| 235 * | |
| 236 * \return A handle to the True object if no error occurs. | |
| 237 */ | |
| 238 DART_EXPORT Dart_Handle Dart_SetBreakpointAtLine( | |
| 239 Dart_Handle script_url, | |
| 240 Dart_Handle line_number, | |
| 241 Dart_Breakpoint* breakpoint); | |
| 242 | |
| 243 | |
| 244 /** | |
| 245 * Sets a one-time breakpoint at the entry of the given function. | 210 * Sets a one-time breakpoint at the entry of the given function. |
| 246 * If class_name is the empty string, looks for a library function | 211 * If class_name is the empty string, looks for a library function |
| 247 * with the given name. | 212 * with the given name. |
| 248 * | 213 * |
| 249 * Requires there to be a current isolate. | 214 * Requires there to be a current isolate. |
| 250 * | 215 * |
| 251 * \breakpoint If non-null, will point to the breakpoint object | 216 * \return A handle containing the breakpoint id, which is an integer |
| 252 * if a breakpoint was successfully created. | 217 * value, or an error object if a breakpoint could not be set. |
| 253 * | |
| 254 * \return A handle to the True object if no error occurs. | |
| 255 */ | 218 */ |
| 256 DART_EXPORT Dart_Handle Dart_SetBreakpointAtEntry( | 219 DART_EXPORT Dart_Handle Dart_SetBreakpointAtEntry( |
| 257 Dart_Handle library, | 220 Dart_Handle library, |
| 258 Dart_Handle class_name, | 221 Dart_Handle class_name, |
| 259 Dart_Handle function_name, | 222 Dart_Handle function_name); |
| 260 Dart_Breakpoint* breakpoint); | |
| 261 | 223 |
| 262 | 224 |
| 263 /** | 225 /** |
| 264 * Sets a breakpoint at the entry of the given function. If class_name | 226 * Sets a breakpoint at the entry of the given function. If class_name |
| 265 * is the empty string, looks for a library function with the given | 227 * is the empty string, looks for a library function with the given |
| 266 * name. | 228 * name. |
| 267 * | 229 * |
| 268 * Requires there to be a current isolate. | 230 * Requires there to be a current isolate. |
| 269 * | 231 * |
| 270 * \return A handle to the True object if no error occurs. | 232 * \return A handle to the True object if no error occurs. |
| 271 */ | 233 */ |
| 272 DART_EXPORT Dart_Handle Dart_OneTimeBreakAtEntry( | 234 DART_EXPORT Dart_Handle Dart_OneTimeBreakAtEntry( |
| 273 Dart_Handle library, | 235 Dart_Handle library, |
| 274 Dart_Handle class_name, | 236 Dart_Handle class_name, |
| 275 Dart_Handle function_name); | 237 Dart_Handle function_name); |
| 276 | 238 |
| 277 | 239 |
| 278 /** | 240 /** |
| 279 * DEPRECATED -- use Dart_RemoveBreakpoint instead. | |
| 280 * | |
| 281 * Deletes the given \breakpoint. | |
| 282 * | |
| 283 * Requires there to be a current isolate. | |
| 284 * | |
| 285 * \return A handle to the True object if no error occurs. | |
| 286 */ | |
| 287 DART_EXPORT Dart_Handle Dart_DeleteBreakpoint( | |
| 288 Dart_Breakpoint breakpoint); | |
| 289 | |
| 290 | |
| 291 /** | |
| 292 * Can be called from the breakpoint handler. Sets the debugger to | 241 * Can be called from the breakpoint handler. Sets the debugger to |
| 293 * single step mode. | 242 * single step mode. |
| 294 * | 243 * |
| 295 * Requires there to be a current isolate. | 244 * Requires there to be a current isolate. |
| 296 */ | 245 */ |
| 297 DART_EXPORT Dart_Handle Dart_SetStepOver(); | 246 DART_EXPORT Dart_Handle Dart_SetStepOver(); |
| 298 | 247 |
| 299 | 248 |
| 300 /** | 249 /** |
| 301 * Can be called from the breakpoint handler. Causes the debugger to | 250 * Can be called from the breakpoint handler. Causes the debugger to |
| (...skipping 338 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 640 * \param request A REST-like string, which uses '/' to separate | 589 * \param request A REST-like string, which uses '/' to separate |
| 641 * parameters. The first parameter is always the status type. | 590 * parameters. The first parameter is always the status type. |
| 642 * | 591 * |
| 643 * \return The requested status as a JSON formatted string, with the | 592 * \return The requested status as a JSON formatted string, with the |
| 644 * contents defined by the status plug-in. The caller is responsible | 593 * contents defined by the status plug-in. The caller is responsible |
| 645 * for freeing this string. | 594 * for freeing this string. |
| 646 */ | 595 */ |
| 647 DART_EXPORT char* Dart_GetVmStatus(const char* request); | 596 DART_EXPORT char* Dart_GetVmStatus(const char* request); |
| 648 | 597 |
| 649 #endif // INCLUDE_DART_DEBUGGER_API_H_ | 598 #endif // INCLUDE_DART_DEBUGGER_API_H_ |
| OLD | NEW |