| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef V8RuntimeAgent_h | 5 #ifndef V8RuntimeAgent_h |
| 6 #define V8RuntimeAgent_h | 6 #define V8RuntimeAgent_h |
| 7 | 7 |
| 8 #include "platform/PlatformExport.h" | 8 #include "platform/PlatformExport.h" |
| 9 #include "platform/inspector_protocol/Dispatcher.h" | 9 #include "platform/inspector_protocol/Dispatcher.h" |
| 10 #include "platform/v8_inspector/public/V8ContextInfo.h" | 10 #include "platform/v8_inspector/public/V8ContextInfo.h" |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 // Cross-context inspectable values (DOM nodes in different worlds, etc.). | 22 // Cross-context inspectable values (DOM nodes in different worlds, etc.). |
| 23 class Inspectable { | 23 class Inspectable { |
| 24 public: | 24 public: |
| 25 virtual v8::Local<v8::Value> get(v8::Local<v8::Context>) = 0; | 25 virtual v8::Local<v8::Value> get(v8::Local<v8::Context>) = 0; |
| 26 virtual ~Inspectable() { } | 26 virtual ~Inspectable() { } |
| 27 }; | 27 }; |
| 28 | 28 |
| 29 virtual ~V8RuntimeAgent() { } | 29 virtual ~V8RuntimeAgent() { } |
| 30 | 30 |
| 31 // Embedder API. | 31 // Embedder API. |
| 32 using ClearConsoleCallback = Function<void()>; | |
| 33 virtual void setClearConsoleCallback(PassOwnPtr<ClearConsoleCallback>) = 0; | |
| 34 virtual PassOwnPtr<protocol::Runtime::RemoteObject> wrapObject(v8::Local<v8:
:Context>, v8::Local<v8::Value>, const String16& groupName, bool generatePreview
= false) = 0; | 32 virtual PassOwnPtr<protocol::Runtime::RemoteObject> wrapObject(v8::Local<v8:
:Context>, v8::Local<v8::Value>, const String16& groupName, bool generatePreview
= false) = 0; |
| 35 // FIXME: remove when console.table moves into V8 inspector. | 33 // FIXME: remove when InspectorConsoleAgent moves into V8 inspector. |
| 36 virtual PassOwnPtr<protocol::Runtime::RemoteObject> wrapTable(v8::Local<v8::
Context>, v8::Local<v8::Value> table, v8::Local<v8::Value> columns) = 0; | 34 virtual PassOwnPtr<protocol::Runtime::RemoteObject> wrapTable(v8::Local<v8::
Context>, v8::Local<v8::Value> table, v8::Local<v8::Value> columns) = 0; |
| 37 virtual v8::Local<v8::Value> findObject(ErrorString*, const String16& object
Id, v8::Local<v8::Context>* = nullptr, String16* objectGroup = nullptr) = 0; | 35 virtual v8::Local<v8::Value> findObject(ErrorString*, const String16& object
Id, v8::Local<v8::Context>* = nullptr, String16* objectGroup = nullptr) = 0; |
| 38 virtual void disposeObjectGroup(const String16&) = 0; | 36 virtual void disposeObjectGroup(const String16&) = 0; |
| 39 virtual void addInspectedObject(PassOwnPtr<Inspectable>) = 0; | 37 virtual void addInspectedObject(PassOwnPtr<Inspectable>) = 0; |
| 40 }; | 38 }; |
| 41 | 39 |
| 42 } // namespace blink | 40 } // namespace blink |
| 43 | 41 |
| 44 #endif // V8RuntimeAgent_h | 42 #endif // V8RuntimeAgent_h |
| OLD | NEW |