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

Side by Side Diff: third_party/WebKit/Source/modules/websockets/DOMWebSocket.h

Issue 1652983005: Remove Enumeration Histograms from the Blink Platform API. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master_blink_histograms_5a
Patch Set: Rebase two new histograms were added today Created 4 years, 10 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after
210 // are just for determining if the optional code argument is supplied or 210 // are just for determining if the optional code argument is supplied or
211 // not. 211 // not.
212 void closeInternal(int, const String&, ExceptionState&); 212 void closeInternal(int, const String&, ExceptionState&);
213 213
214 // Updates m_bufferedAmountAfterClose given the amount of data passed to 214 // Updates m_bufferedAmountAfterClose given the amount of data passed to
215 // send() method after the state changed to CLOSING or CLOSED. 215 // send() method after the state changed to CLOSING or CLOSED.
216 void updateBufferedAmountAfterClose(uint64_t); 216 void updateBufferedAmountAfterClose(uint64_t);
217 void reflectBufferedAmountConsumption(Timer<DOMWebSocket>*); 217 void reflectBufferedAmountConsumption(Timer<DOMWebSocket>*);
218 218
219 void releaseChannel(); 219 void releaseChannel();
220 void recordSendTypeHistogram(WebSocketSendType);
221 void recordReceiveTypeHistogram(WebSocketReceiveType);
220 222
221 enum BinaryType { 223 enum BinaryType {
222 BinaryTypeBlob, 224 BinaryTypeBlob,
223 BinaryTypeArrayBuffer 225 BinaryTypeArrayBuffer
224 }; 226 };
225 227
226 Member<WebSocketChannel> m_channel; 228 Member<WebSocketChannel> m_channel;
227 229
228 State m_state; 230 State m_state;
229 KURL m_url; 231 KURL m_url;
230 uint64_t m_bufferedAmount; 232 uint64_t m_bufferedAmount;
231 // The consumed buffered amount that will be reflected to m_bufferedAmount 233 // The consumed buffered amount that will be reflected to m_bufferedAmount
232 // later. It will be cleared once reflected. 234 // later. It will be cleared once reflected.
233 uint64_t m_consumedBufferedAmount; 235 uint64_t m_consumedBufferedAmount;
234 uint64_t m_bufferedAmountAfterClose; 236 uint64_t m_bufferedAmountAfterClose;
235 BinaryType m_binaryType; 237 BinaryType m_binaryType;
236 // The subprotocol the server selected. 238 // The subprotocol the server selected.
237 String m_subprotocol; 239 String m_subprotocol;
238 String m_extensions; 240 String m_extensions;
239 241
240 Member<EventQueue> m_eventQueue; 242 Member<EventQueue> m_eventQueue;
241 Timer<DOMWebSocket> m_bufferedAmountConsumeTimer; 243 Timer<DOMWebSocket> m_bufferedAmountConsumeTimer;
242 }; 244 };
243 245
244 } // namespace blink 246 } // namespace blink
245 247
246 #endif // DOMWebSocket_h 248 #endif // DOMWebSocket_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698