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

Side by Side Diff: content/browser/bluetooth/bluetooth_metrics.h

Issue 2654403002: Implement WebBluetooth descriptor.writeValue() (Closed)
Patch Set: #4 Created 3 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
« no previous file with comments | « no previous file | content/browser/bluetooth/bluetooth_metrics.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_BROWSER_BLUETOOTH_BLUETOOTH_METRICS_H_ 5 #ifndef CONTENT_BROWSER_BLUETOOTH_BLUETOOTH_METRICS_H_
6 #define CONTENT_BROWSER_BLUETOOTH_BLUETOOTH_METRICS_H_ 6 #define CONTENT_BROWSER_BLUETOOTH_BLUETOOTH_METRICS_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 18 matching lines...) Expand all
29 GET_PRIMARY_SERVICE = 2, 29 GET_PRIMARY_SERVICE = 2,
30 SERVICE_GET_CHARACTERISTIC = 3, 30 SERVICE_GET_CHARACTERISTIC = 3,
31 CHARACTERISTIC_READ_VALUE = 4, 31 CHARACTERISTIC_READ_VALUE = 4,
32 CHARACTERISTIC_WRITE_VALUE = 5, 32 CHARACTERISTIC_WRITE_VALUE = 5,
33 CHARACTERISTIC_START_NOTIFICATIONS = 6, 33 CHARACTERISTIC_START_NOTIFICATIONS = 6,
34 CHARACTERISTIC_STOP_NOTIFICATIONS = 7, 34 CHARACTERISTIC_STOP_NOTIFICATIONS = 7,
35 REMOTE_GATT_SERVER_DISCONNECT = 8, 35 REMOTE_GATT_SERVER_DISCONNECT = 8,
36 SERVICE_GET_CHARACTERISTICS = 9, 36 SERVICE_GET_CHARACTERISTICS = 9,
37 GET_PRIMARY_SERVICES = 10, 37 GET_PRIMARY_SERVICES = 10,
38 DESCRIPTOR_READ_VALUE = 11, 38 DESCRIPTOR_READ_VALUE = 11,
39 DESCRIPTOR_WRITE_VALUE = 12,
39 // NOTE: Add new actions immediately above this line. Make sure to update 40 // NOTE: Add new actions immediately above this line. Make sure to update
40 // the enum list in tools/metrics/histograms/histograms.xml accordingly. 41 // the enum list in tools/metrics/histograms/histograms.xml accordingly.
41 COUNT 42 COUNT
42 }; 43 };
43 44
44 // There should be a call to this function for every call to the Web Bluetooth 45 // There should be a call to this function for every call to the Web Bluetooth
45 // API. 46 // API.
46 void RecordWebBluetoothFunctionCall(UMAWebBluetoothFunction function); 47 void RecordWebBluetoothFunctionCall(UMAWebBluetoothFunction function);
47 48
48 // Enumeration for outcomes of querying the bluetooth cache. 49 // Enumeration for outcomes of querying the bluetooth cache.
(...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after
232 // Make sure to update the enum list in 233 // Make sure to update the enum list in
233 // tools/metrics/histograms/histograms.xml accordingly. 234 // tools/metrics/histograms/histograms.xml accordingly.
234 COUNT 235 COUNT
235 }; 236 };
236 237
237 enum class UMAGATTOperation { 238 enum class UMAGATTOperation {
238 CHARACTERISTIC_READ, 239 CHARACTERISTIC_READ,
239 CHARACTERISTIC_WRITE, 240 CHARACTERISTIC_WRITE,
240 START_NOTIFICATIONS, 241 START_NOTIFICATIONS,
241 DESCRIPTOR_READ, 242 DESCRIPTOR_READ,
243 DESCRIPTOR_WRITE,
242 // Note: Add new GATT Operations immediately above this line. 244 // Note: Add new GATT Operations immediately above this line.
243 COUNT 245 COUNT
244 }; 246 };
245 247
246 // Records the outcome of a GATT operation. 248 // Records the outcome of a GATT operation.
247 // There should be a call to this function whenever the corresponding operation 249 // There should be a call to this function whenever the corresponding operation
248 // doesn't have a call to Record[Operation]Outcome. 250 // doesn't have a call to Record[Operation]Outcome.
249 void RecordGATTOperationOutcome(UMAGATTOperation operation, 251 void RecordGATTOperationOutcome(UMAGATTOperation operation,
250 UMAGATTOperationOutcome outcome); 252 UMAGATTOperationOutcome outcome);
251 253
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
308 void RecordRSSISignalStrengthLevel(UMARSSISignalStrengthLevel level); 310 void RecordRSSISignalStrengthLevel(UMARSSISignalStrengthLevel level);
309 311
310 // In the case of not accepting all devices in the options that are given 312 // In the case of not accepting all devices in the options that are given
311 // to WebBluetooth requestDevice(), records the number of devices in the 313 // to WebBluetooth requestDevice(), records the number of devices in the
312 // chooser when a device is paired. 314 // chooser when a device is paired.
313 void RecordNumOfDevices(bool accept_all_devices, size_t num_of_devices); 315 void RecordNumOfDevices(bool accept_all_devices, size_t num_of_devices);
314 316
315 } // namespace content 317 } // namespace content
316 318
317 #endif // CONTENT_BROWSER_BLUETOOTH_BLUETOOTH_METRICS_H_ 319 #endif // CONTENT_BROWSER_BLUETOOTH_BLUETOOTH_METRICS_H_
OLDNEW
« no previous file with comments | « no previous file | content/browser/bluetooth/bluetooth_metrics.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698