OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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 RUNTIME_VM_DEBUGGER_H_ | 5 #ifndef RUNTIME_VM_DEBUGGER_H_ |
6 #define RUNTIME_VM_DEBUGGER_H_ | 6 #define RUNTIME_VM_DEBUGGER_H_ |
7 | 7 |
8 #include "include/dart_tools_api.h" | 8 #include "include/dart_tools_api.h" |
9 | 9 |
10 #include "vm/object.h" | 10 #include "vm/object.h" |
(...skipping 436 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
447 | 447 |
448 typedef void EventHandler(ServiceEvent* event); | 448 typedef void EventHandler(ServiceEvent* event); |
449 | 449 |
450 Debugger(); | 450 Debugger(); |
451 ~Debugger(); | 451 ~Debugger(); |
452 | 452 |
453 void Initialize(Isolate* isolate); | 453 void Initialize(Isolate* isolate); |
454 void NotifyIsolateCreated(); | 454 void NotifyIsolateCreated(); |
455 void Shutdown(); | 455 void Shutdown(); |
456 | 456 |
| 457 void OnIsolateRunnable(); |
| 458 |
457 void NotifyCompilation(const Function& func); | 459 void NotifyCompilation(const Function& func); |
458 void NotifyDoneLoading(); | 460 void NotifyDoneLoading(); |
459 | 461 |
460 RawFunction* ResolveFunction(const Library& library, | 462 RawFunction* ResolveFunction(const Library& library, |
461 const String& class_name, | 463 const String& class_name, |
462 const String& function_name); | 464 const String& function_name); |
463 | 465 |
464 // Set breakpoint at closest location to function entry. | 466 // Set breakpoint at closest location to function entry. |
465 Breakpoint* SetBreakpointAtEntry(const Function& target_function, | 467 Breakpoint* SetBreakpointAtEntry(const Function& target_function, |
466 bool single_shot); | 468 bool single_shot); |
(...skipping 10 matching lines...) Expand all Loading... |
477 RawError* OneTimeBreakAtEntry(const Function& target_function); | 479 RawError* OneTimeBreakAtEntry(const Function& target_function); |
478 | 480 |
479 BreakpointLocation* BreakpointLocationAtLineCol(const String& script_url, | 481 BreakpointLocation* BreakpointLocationAtLineCol(const String& script_url, |
480 intptr_t line_number, | 482 intptr_t line_number, |
481 intptr_t column_number); | 483 intptr_t column_number); |
482 | 484 |
483 | 485 |
484 void RemoveBreakpoint(intptr_t bp_id); | 486 void RemoveBreakpoint(intptr_t bp_id); |
485 Breakpoint* GetBreakpointById(intptr_t id); | 487 Breakpoint* GetBreakpointById(intptr_t id); |
486 | 488 |
| 489 void MaybeAsyncStepInto(const Closure& async_op); |
| 490 |
| 491 void Continue(); |
| 492 |
487 bool SetResumeAction(ResumeAction action, | 493 bool SetResumeAction(ResumeAction action, |
488 intptr_t frame_index = 1, | 494 intptr_t frame_index = 1, |
489 const char** error = NULL); | 495 const char** error = NULL); |
490 | 496 |
491 bool IsStepping() const { return resume_action_ != kContinue; } | 497 bool IsStepping() const { return resume_action_ != kContinue; } |
492 | 498 |
| 499 bool IsSingleStepping() const { return resume_action_ == kStepInto; } |
| 500 |
493 bool IsPaused() const { return pause_event_ != NULL; } | 501 bool IsPaused() const { return pause_event_ != NULL; } |
494 | 502 |
495 // Put the isolate into single stepping mode when Dart code next runs. | 503 // Put the isolate into single stepping mode when Dart code next runs. |
496 // | 504 // |
497 // This is used by the vm service to allow the user to step while | 505 // This is used by the vm service to allow the user to step while |
498 // paused at isolate start. | 506 // paused at isolate start. |
499 void EnterSingleStepMode(); | 507 void EnterSingleStepMode(); |
500 | 508 |
501 // Indicates why the debugger is currently paused. If the debugger | 509 // Indicates why the debugger is currently paused. If the debugger |
502 // is not paused, this returns NULL. Note that the debugger can be | 510 // is not paused, this returns NULL. Note that the debugger can be |
(...skipping 252 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
755 | 763 |
756 friend class Isolate; | 764 friend class Isolate; |
757 friend class BreakpointLocation; | 765 friend class BreakpointLocation; |
758 DISALLOW_COPY_AND_ASSIGN(Debugger); | 766 DISALLOW_COPY_AND_ASSIGN(Debugger); |
759 }; | 767 }; |
760 | 768 |
761 | 769 |
762 } // namespace dart | 770 } // namespace dart |
763 | 771 |
764 #endif // RUNTIME_VM_DEBUGGER_H_ | 772 #endif // RUNTIME_VM_DEBUGGER_H_ |
OLD | NEW |