| Index: ui/devtools/devtools_client.h
|
| diff --git a/ui/devtools/devtools_client.h b/ui/devtools/devtools_client.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..b6de7db90c8222abbfa2802d0a7e5c89772d5298
|
| --- /dev/null
|
| +++ b/ui/devtools/devtools_client.h
|
| @@ -0,0 +1,46 @@
|
| +// Copyright 2016 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#ifndef UI_DEVTOOLS_CLIENT_H
|
| +#define UI_DEVTOOLS_CLIENT_H
|
| +
|
| +#include <string>
|
| +
|
| +#include "ui/devtools/DOM.h"
|
| +#include "ui/devtools/Forward.h"
|
| +#include "ui/devtools/Protocol.h"
|
| +#include "ui/devtools/StringUtil.h"
|
| +
|
| +namespace ui {
|
| +namespace devtools {
|
| +
|
| +class UiDevToolsServer;
|
| +class UiDevToolsClient : public protocol::FrontendChannel {
|
| + public:
|
| + UiDevToolsClient(String name, UiDevToolsServer* server);
|
| + ~UiDevToolsClient() override;
|
| +
|
| + void AddDOMBackend(std::unique_ptr<protocol::DOM::Backend> dom_backend);
|
| +
|
| + private:
|
| + friend class UiDevToolsServer;
|
| + void Dispatch(const String& data);
|
| +
|
| + // FrontendChannel
|
| + void sendProtocolResponse(int callId, const String& message) override;
|
| + void sendProtocolNotification(const String& message) override;
|
| + void flushProtocolNotifications() override;
|
| +
|
| + std::string name_;
|
| + int connected_client_id;
|
| +
|
| + std::unique_ptr<protocol::DOM::Backend> dom_backend_;
|
| + protocol::UberDispatcher dispatcher_;
|
| + UiDevToolsServer* server_;
|
| +};
|
| +
|
| +} // namespace devtools
|
| +} // namespace ui
|
| +
|
| +#endif // UI_DEVTOOLS_CLIENT_H_
|
|
|