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

Unified Diff: Source/modules/websockets/WebSocketHandshake.h

Issue 15451002: Start collecting two new WebSocket histograms. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Add comment about reset() Created 7 years, 7 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 | « Source/modules/websockets/WebSocketDeflater.h ('k') | Source/modules/websockets/WebSocketHandshake.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/websockets/WebSocketHandshake.h
diff --git a/Source/modules/websockets/WebSocketHandshake.h b/Source/modules/websockets/WebSocketHandshake.h
index 803f70883f496224f0b9f2dbd249383746a04cfb..f7747050880ec351291aed4a5618ff78d1bb388e 100644
--- a/Source/modules/websockets/WebSocketHandshake.h
+++ b/Source/modules/websockets/WebSocketHandshake.h
@@ -46,8 +46,11 @@ class ScriptExecutionContext;
class WebSocketHandshake {
WTF_MAKE_NONCOPYABLE(WebSocketHandshake); WTF_MAKE_FAST_ALLOCATED;
public:
+ // This enum is reused for histogram. When this needs to be modified, add a
+ // new enum for histogram and convert mode values into values in the new
+ // enum to keep new data consistent with old one.
enum Mode {
- Incomplete, Normal, Failed, Connected
+ Incomplete, Normal, Failed, Connected, ModeMax
};
WebSocketHandshake(const KURL&, const String& protocol, ScriptExecutionContext*);
~WebSocketHandshake();
@@ -67,6 +70,8 @@ public:
CString clientHandshakeMessage() const;
PassRefPtr<WebSocketHandshakeRequest> clientHandshakeRequest() const;
+ // We're collecting data for histogram in the destructor. Note that calling
+ // this method affects that.
void reset();
void clearScriptExecutionContext();
« no previous file with comments | « Source/modules/websockets/WebSocketDeflater.h ('k') | Source/modules/websockets/WebSocketHandshake.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698