| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 CHROME_BROWSER_CHROMEOS_ARC_ARC_OPTIN_UMA_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_ARC_ARC_OPTIN_UMA_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_ARC_ARC_OPTIN_UMA_H_ | 6 #define CHROME_BROWSER_CHROMEOS_ARC_ARC_OPTIN_UMA_H_ |
| 7 | 7 |
| 8 #include <ostream> |
| 9 |
| 8 namespace base { | 10 namespace base { |
| 9 class TimeDelta; | 11 class TimeDelta; |
| 10 } | 12 } |
| 11 | 13 |
| 12 namespace arc { | 14 namespace arc { |
| 13 | 15 |
| 14 // These enums are used to define the buckets for an enumerated UMA histogram | 16 // These enums are used to define the buckets for an enumerated UMA histogram |
| 15 // and need to be synced with histograms.xml | 17 // and need to be synced with histograms.xml |
| 16 enum class OptInActionType : int { | 18 enum class OptInActionType : int { |
| 17 OPTED_OUT = 0, // Arc was opted out by user. | 19 OPTED_OUT = 0, // Arc was opted out by user. |
| (...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 113 | 115 |
| 114 void UpdateOptInActionUMA(OptInActionType type); | 116 void UpdateOptInActionUMA(OptInActionType type); |
| 115 void UpdateOptInCancelUMA(OptInCancelReason reason); | 117 void UpdateOptInCancelUMA(OptInCancelReason reason); |
| 116 void UpdateEnabledStateUMA(bool enabled); | 118 void UpdateEnabledStateUMA(bool enabled); |
| 117 void UpdateProvisioningResultUMA(ProvisioningResult result, bool managed); | 119 void UpdateProvisioningResultUMA(ProvisioningResult result, bool managed); |
| 118 void UpdateProvisioningTiming(const base::TimeDelta& elapsed_time, | 120 void UpdateProvisioningTiming(const base::TimeDelta& elapsed_time, |
| 119 bool success, | 121 bool success, |
| 120 bool managed); | 122 bool managed); |
| 121 void UpdateSilentAuthCodeUMA(OptInSilentAuthCode state); | 123 void UpdateSilentAuthCodeUMA(OptInSilentAuthCode state); |
| 122 | 124 |
| 125 // Outputs the stringified |result| to |os|. This is only for logging purposes. |
| 126 std::ostream& operator<<(std::ostream& os, const ProvisioningResult& result); |
| 127 |
| 123 } // namespace arc | 128 } // namespace arc |
| 124 | 129 |
| 125 #endif // CHROME_BROWSER_CHROMEOS_ARC_ARC_OPTIN_UMA_H_ | 130 #endif // CHROME_BROWSER_CHROMEOS_ARC_ARC_OPTIN_UMA_H_ |
| OLD | NEW |