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

Unified Diff: webrtc/common_types.h

Issue 2589773002: CodecInst operator<< (Closed)
Patch Set: Created 4 years 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/common_types.h
diff --git a/webrtc/common_types.h b/webrtc/common_types.h
index 2988bf9f41a6fb8763cb31342217e24b4fe8d879..fd5d8208927e67b764a7ab78f4e96fd5d4eed5ba 100644
--- a/webrtc/common_types.h
+++ b/webrtc/common_types.h
@@ -14,6 +14,7 @@
#include <stddef.h>
#include <string.h>
+#include <ostream>
#include <string>
#include <vector>
@@ -328,6 +329,16 @@ struct CodecInst {
}
bool operator!=(const CodecInst& other) const { return !(*this == other); }
+
+ friend std::ostream& operator<<(std::ostream& os, const CodecInst& ci) {
+ os << "{pltype: " << ci.pltype;
+ os << ", plname: " << ci.plname;
+ os << ", plfreq: " << ci.plfreq;
+ os << ", pacsize: " << ci.pacsize;
+ os << ", channels: " << ci.channels;
+ os << ", rate: " << ci.rate << "}";
+ return os;
+ }
};
// RTP
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698