Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(763)

Unified Diff: components/devtools_bridge/client/web_client.h

Issue 746663002: Stub for WebRTCDeviceProvider (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@webclient
Patch Set: Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/devtools_bridge/client/web_client.h
diff --git a/components/devtools_bridge/client/web_client.h b/components/devtools_bridge/client/web_client.h
index d980e8710954d76abd3a540d67b41a5a9c0f8a1b..7d5f597a64dc3749ce83a6d42d423a74d55981f8 100644
--- a/components/devtools_bridge/client/web_client.h
+++ b/components/devtools_bridge/client/web_client.h
@@ -5,6 +5,9 @@
#ifndef COMPONENTS_DEVTOOLS_BRIDGE_CLIENT_WEB_CLIENT_H_
#define COMPONENTS_DEVTOOLS_BRIDGE_CLIENT_WEB_CLIENT_H_
+#include <string>
+
+#include "base/callback.h"
#include "base/memory/scoped_ptr.h"
namespace content {
@@ -21,10 +24,16 @@ namespace devtools_bridge {
*/
class WebClient {
public:
+ typedef base::Callback<void (const std::string& respose)>
+ CommandSuccessCallback;
+ typedef base::Closure CommandFailureCallback;
+
class Delegate {
public:
- // TODO(serya): implement
+ virtual void SendCommand(const std::string& command,
+ const CommandSuccessCallback& sucess_callback,
+ const CommandFailureCallback& failure_callback) {}
};
virtual ~WebClient() {}
@@ -32,6 +41,10 @@ class WebClient {
static scoped_ptr<WebClient> CreateInstance(
content::BrowserContext* context, Delegate* delegate);
+ virtual void Connect(const std::string& device_id) = 0;
+ virtual void Disconnect(const std::string& device_id) = 0;
+ virtual void DisconnectAll() = 0;
+
// TODO(serya): Implement.
protected:

Powered by Google App Engine
This is Rietveld 408576698