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

Unified Diff: lib/FrontendChannel_h.template

Issue 2526603002: [inspector_protocol] Introduce protocol::Serializable (Closed)
Patch Set: minor fix Created 4 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
« no previous file with comments | « lib/DispatcherBase_h.template ('k') | lib/Maybe_h.template » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/FrontendChannel_h.template
diff --git a/lib/FrontendChannel_h.template b/lib/FrontendChannel_h.template
index 8b653b58214b80aaa2f288043aa45866e3346e45..0454978b0c8e88116cf89c66c0a4a9be6460f4f5 100644
--- a/lib/FrontendChannel_h.template
+++ b/lib/FrontendChannel_h.template
@@ -9,11 +9,17 @@
namespace {{namespace}} {
{% endfor %}
+class {{config.lib.export_macro}} Serializable {
+public:
+ virtual String serialize() = 0;
+ virtual ~Serializable() = default;
+};
+
class {{config.lib.export_macro}} FrontendChannel {
public:
virtual ~FrontendChannel() { }
- virtual void sendProtocolResponse(int callId, const String& message) = 0;
- virtual void sendProtocolNotification(const String& message) = 0;
+ virtual void sendProtocolResponse(int callId, std::unique_ptr<Serializable> message) = 0;
+ virtual void sendProtocolNotification(std::unique_ptr<Serializable> message) = 0;
virtual void flushProtocolNotifications() = 0;
};
« no previous file with comments | « lib/DispatcherBase_h.template ('k') | lib/Maybe_h.template » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698