| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 CONTENT_PUBLIC_BROWSER_DEVTOOLS_EXTERNAL_AGENT_PROXY_DELEGATE_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_DEVTOOLS_EXTERNAL_AGENT_PROXY_DELEGATE_H_ |
| 6 #define CONTENT_PUBLIC_BROWSER_DEVTOOLS_EXTERNAL_AGENT_PROXY_DELEGATE_H_ | 6 #define CONTENT_PUBLIC_BROWSER_DEVTOOLS_EXTERNAL_AGENT_PROXY_DELEGATE_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "content/common/content_export.h" | 10 #include "content/common/content_export.h" |
| 11 | 11 |
| 12 namespace content { | 12 namespace content { |
| 13 | 13 |
| 14 class DevToolsExternalAgentProxy; | 14 class DevToolsExternalAgentProxy; |
| 15 | 15 |
| 16 // Describes the interface for sending messages to an external DevTools agent. | 16 // Describes the interface for sending messages to an external DevTools agent. |
| 17 class DevToolsExternalAgentProxyDelegate { | 17 class DevToolsExternalAgentProxyDelegate { |
| 18 public: | 18 public: |
| 19 virtual ~DevToolsExternalAgentProxyDelegate() {} | 19 virtual ~DevToolsExternalAgentProxyDelegate() {} |
| 20 | 20 |
| 21 // Informs the agent that a client host has attached. | 21 // Informs the agent that a client host has attached. |
| 22 virtual void Attach(DevToolsExternalAgentProxy* proxy) = 0; | 22 virtual void Attach(DevToolsExternalAgentProxy* proxy) = 0; |
| 23 | 23 |
| 24 // Informs the agent that a client host has detached. | 24 // Informs the agent that a client host has detached. |
| 25 virtual void Detach() = 0; | 25 virtual void Detach() = 0; |
| 26 | 26 |
| 27 // Returns agent host id. | 27 // Sends a message to the agent. |
| 28 virtual std::string GetId() = 0; | 28 virtual void SendMessageToBackend(const std::string& message) = 0; |
| 29 | |
| 30 // Returns agent host type. | |
| 31 virtual std::string GetType() = 0; | |
| 32 | |
| 33 // Returns agent host title. | |
| 34 virtual std::string GetTitle() = 0; | |
| 35 | |
| 36 // Returns the agent host description. | |
| 37 virtual std::string GetDescription() = 0; | |
| 38 | |
| 39 // Returns url associated with agent host. | |
| 40 virtual GURL GetURL() = 0; | |
| 41 | |
| 42 // Returns the favicon url for this agent host. | |
| 43 virtual GURL GetFaviconURL() = 0; | |
| 44 | |
| 45 // Activates agent host. | |
| 46 virtual bool Activate() = 0; | |
| 47 | |
| 48 // Initiates external agent host inspection. | |
| 49 virtual bool Inspect() = 0; | |
| 50 | |
| 51 // Reloads agent host. | |
| 52 virtual void Reload() = 0; | |
| 53 | |
| 54 // Reloads agent host. | |
| 55 virtual bool Close() = 0; | |
| 56 | |
| 57 // Sends a message to the agent. | |
| 58 virtual void SendMessageToBackend(const std::string& message) = 0; | |
| 59 }; | 29 }; |
| 60 | 30 |
| 61 } // namespace content | 31 } // namespace content |
| 62 | 32 |
| 63 #endif // CONTENT_PUBLIC_BROWSER_DEVTOOLS_EXTERNAL_AGENT_PROXY_DELEGATE_H_ | 33 #endif // CONTENT_PUBLIC_BROWSER_DEVTOOLS_EXTERNAL_AGENT_PROXY_DELEGATE_H_ |
| OLD | NEW |