OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CHROME_TEST_CHROMEDRIVER_DEVTOOLS_CLIENT_H_ | 5 #ifndef CHROME_TEST_CHROMEDRIVER_DEVTOOLS_CLIENT_H_ |
6 #define CHROME_TEST_CHROMEDRIVER_DEVTOOLS_CLIENT_H_ | 6 #define CHROME_TEST_CHROMEDRIVER_DEVTOOLS_CLIENT_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
11 | 11 |
12 namespace base { | 12 namespace base { |
13 class DictionaryValue; | 13 class DictionaryValue; |
14 } | 14 } |
15 | 15 |
| 16 class DevToolsEventListener; |
16 class Status; | 17 class Status; |
17 | 18 |
18 // A DevTools client of a single DevTools debugger. | 19 // A DevTools client of a single DevTools debugger. |
19 class DevToolsClient { | 20 class DevToolsClient { |
20 public: | 21 public: |
21 virtual ~DevToolsClient() {} | 22 virtual ~DevToolsClient() {} |
22 | 23 |
23 virtual Status SendCommand(const std::string& method, | 24 virtual Status SendCommand(const std::string& method, |
24 const base::DictionaryValue& params) = 0; | 25 const base::DictionaryValue& params) = 0; |
25 virtual Status SendCommandAndGetResult( | 26 virtual Status SendCommandAndGetResult( |
26 const std::string& method, | 27 const std::string& method, |
27 const base::DictionaryValue& params, | 28 const base::DictionaryValue& params, |
28 scoped_ptr<base::DictionaryValue>* result) = 0; | 29 scoped_ptr<base::DictionaryValue>* result) = 0; |
| 30 |
| 31 virtual void AddListener(DevToolsEventListener* listener) = 0; |
29 }; | 32 }; |
30 | 33 |
31 #endif // CHROME_TEST_CHROMEDRIVER_DEVTOOLS_CLIENT_H_ | 34 #endif // CHROME_TEST_CHROMEDRIVER_DEVTOOLS_CLIENT_H_ |
OLD | NEW |