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

Unified Diff: blimp/net/common.cc

Issue 1551583003: Implementation and fixes for Blimp client/engine E2E communication. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@dtrainor-linux-cl1528243002
Patch Set: Fixed misplaced EXPORT directive Created 4 years, 12 months 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 | « blimp/net/common.h ('k') | blimp/net/engine_authentication_handler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: blimp/net/common.cc
diff --git a/blimp/net/common.cc b/blimp/net/common.cc
index 1663b300534f03ff610710b6d2630a5f7c04c427..c4f01483cecb028ee7bbd7cbe11bd206edbc67b6 100644
--- a/blimp/net/common.cc
+++ b/blimp/net/common.cc
@@ -4,9 +4,21 @@
#include "blimp/net/common.h"
+#include <iostream>
+
+#include "blimp/common/proto/blimp_message.pb.h"
+#include "net/base/ip_address_number.h"
+
namespace blimp {
const size_t kMaxPacketPayloadSizeBytes = 1 << 16; // 64KB
const size_t kPacketHeaderSizeBytes = 4;
+std::ostream& operator<<(std::ostream& out, const BlimpMessage& message) {
+ // TODO(kmarshall): Look into including type-specific fields in the output.
+ out << "<BlimpMessage type=" << message.type()
+ << ", size=" << message.ByteSize() << ">";
+ return out;
+}
+
} // namespace blimp
« no previous file with comments | « blimp/net/common.h ('k') | blimp/net/engine_authentication_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698