OLD | NEW |
1 // Copyright 2006-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2008 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 506 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
517 bool is_event_; // Does this message represent a debug event? | 517 bool is_event_; // Does this message represent a debug event? |
518 DebugEvent event_; // Debug event causing the break. | 518 DebugEvent event_; // Debug event causing the break. |
519 bool running_; // Will the VM start running after this event? | 519 bool running_; // Will the VM start running after this event? |
520 Handle<JSObject> exec_state_; // Current execution state. | 520 Handle<JSObject> exec_state_; // Current execution state. |
521 Handle<JSObject> event_data_; // Data associated with the event. | 521 Handle<JSObject> event_data_; // Data associated with the event. |
522 Handle<String> response_json_; // Response JSON if message holds a response. | 522 Handle<String> response_json_; // Response JSON if message holds a response. |
523 v8::Debug::ClientData* client_data_; // Client data passed with the request. | 523 v8::Debug::ClientData* client_data_; // Client data passed with the request. |
524 }; | 524 }; |
525 | 525 |
526 | 526 |
| 527 // Details of the debug event delivered to the debug event listener. |
| 528 class EventDetailsImpl : public v8::Debug::EventDetails { |
| 529 public: |
| 530 EventDetailsImpl(DebugEvent event, |
| 531 Handle<JSObject> exec_state, |
| 532 Handle<JSObject> event_data, |
| 533 Handle<Object> callback_data); |
| 534 virtual DebugEvent GetEvent() const; |
| 535 virtual v8::Handle<v8::Object> GetExecutionState() const; |
| 536 virtual v8::Handle<v8::Object> GetEventData() const; |
| 537 virtual v8::Handle<v8::Context> GetEventContext() const; |
| 538 virtual v8::Handle<v8::Value> GetCallbackData() const; |
| 539 private: |
| 540 DebugEvent event_; // Debug event causing the break. |
| 541 Handle<JSObject> exec_state_; // Current execution state. |
| 542 Handle<JSObject> event_data_; // Data associated with the event. |
| 543 Handle<Object> callback_data_; // User data passed with the callback when |
| 544 // it was registered. |
| 545 }; |
| 546 |
| 547 |
527 // Message send by user to v8 debugger or debugger output message. | 548 // Message send by user to v8 debugger or debugger output message. |
528 // In addition to command text it may contain a pointer to some user data | 549 // In addition to command text it may contain a pointer to some user data |
529 // which are expected to be passed along with the command reponse to message | 550 // which are expected to be passed along with the command reponse to message |
530 // handler. | 551 // handler. |
531 class CommandMessage { | 552 class CommandMessage { |
532 public: | 553 public: |
533 static CommandMessage New(const Vector<uint16_t>& command, | 554 static CommandMessage New(const Vector<uint16_t>& command, |
534 v8::Debug::ClientData* data); | 555 v8::Debug::ClientData* data); |
535 CommandMessage(); | 556 CommandMessage(); |
536 ~CommandMessage(); | 557 ~CommandMessage(); |
(...skipping 369 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
906 | 927 |
907 DISALLOW_COPY_AND_ASSIGN(MessageDispatchHelperThread); | 928 DISALLOW_COPY_AND_ASSIGN(MessageDispatchHelperThread); |
908 }; | 929 }; |
909 | 930 |
910 | 931 |
911 } } // namespace v8::internal | 932 } } // namespace v8::internal |
912 | 933 |
913 #endif // ENABLE_DEBUGGER_SUPPORT | 934 #endif // ENABLE_DEBUGGER_SUPPORT |
914 | 935 |
915 #endif // V8_DEBUG_H_ | 936 #endif // V8_DEBUG_H_ |
OLD | NEW |