| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 // This file defines a set of user experience metrics data recorded by | 5 // This file defines a set of user experience metrics data recorded by |
| 6 // the MetricsService. This is the unit of data that is sent to the server. | 6 // the MetricsService. This is the unit of data that is sent to the server. |
| 7 | 7 |
| 8 #ifndef CHROME_BROWSER_METRICS_METRICS_LOG_H_ | 8 #ifndef CHROME_BROWSER_METRICS_METRICS_LOG_H_ |
| 9 #define CHROME_BROWSER_METRICS_METRICS_LOG_H_ | 9 #define CHROME_BROWSER_METRICS_METRICS_LOG_H_ |
| 10 | 10 |
| 11 #include <string> | 11 #include <string> |
| 12 #include <vector> | 12 #include <vector> |
| 13 | 13 |
| 14 #include "base/basictypes.h" | 14 #include "base/basictypes.h" |
| 15 #include "chrome/browser/metrics/extension_metrics.h" | 15 #include "chrome/browser/metrics/extension_metrics.h" |
| 16 #include "chrome/browser/metrics/metrics_network_observer.h" | 16 #include "chrome/browser/metrics/metrics_network_observer.h" |
| 17 #include "chrome/common/metrics/metrics_log_base.h" | |
| 18 #include "chrome/common/metrics/variations/variations_util.h" | 17 #include "chrome/common/metrics/variations/variations_util.h" |
| 19 #include "chrome/installer/util/google_update_settings.h" | 18 #include "chrome/installer/util/google_update_settings.h" |
| 19 #include "components/metrics/metrics_log_base.h" |
| 20 #include "ui/gfx/size.h" | 20 #include "ui/gfx/size.h" |
| 21 | 21 |
| 22 class HashedExtensionMetrics; | 22 class HashedExtensionMetrics; |
| 23 class MetricsNetworkObserver; | 23 class MetricsNetworkObserver; |
| 24 struct OmniboxLog; | 24 struct OmniboxLog; |
| 25 class PrefService; | 25 class PrefService; |
| 26 class PrefRegistrySimple; | 26 class PrefRegistrySimple; |
| 27 | 27 |
| 28 #if defined(OS_CHROMEOS) | 28 #if defined(OS_CHROMEOS) |
| 29 class MetricsLogChromeOS; | 29 class MetricsLogChromeOS; |
| (...skipping 27 matching lines...) Expand all Loading... |
| 57 base::Time last_started_au; | 57 base::Time last_started_au; |
| 58 // The time at which Google Update last successfully recieved update | 58 // The time at which Google Update last successfully recieved update |
| 59 // information from Google servers. | 59 // information from Google servers. |
| 60 base::Time last_checked; | 60 base::Time last_checked; |
| 61 // Details about Google Update's attempts to update itself. | 61 // Details about Google Update's attempts to update itself. |
| 62 GoogleUpdateSettings::ProductData google_update_data; | 62 GoogleUpdateSettings::ProductData google_update_data; |
| 63 // Details about Google Update's attempts to update this product. | 63 // Details about Google Update's attempts to update this product. |
| 64 GoogleUpdateSettings::ProductData product_data; | 64 GoogleUpdateSettings::ProductData product_data; |
| 65 }; | 65 }; |
| 66 | 66 |
| 67 class MetricsLog : public MetricsLogBase { | 67 class MetricsLog : public metrics::MetricsLogBase { |
| 68 public: | 68 public: |
| 69 // Creates a new metrics log of the specified type. | 69 // Creates a new metrics log of the specified type. |
| 70 // client_id is the identifier for this profile on this installation | 70 // client_id is the identifier for this profile on this installation |
| 71 // session_id is an integer that's incremented on each application launch | 71 // session_id is an integer that's incremented on each application launch |
| 72 MetricsLog(const std::string& client_id, int session_id, LogType log_type); | 72 MetricsLog(const std::string& client_id, int session_id, LogType log_type); |
| 73 virtual ~MetricsLog(); | 73 virtual ~MetricsLog(); |
| 74 | 74 |
| 75 static void RegisterPrefs(PrefRegistrySimple* registry); | 75 static void RegisterPrefs(PrefRegistrySimple* registry); |
| 76 | 76 |
| 77 // Get the current version of the application as a string. | 77 // Get the current version of the application as a string. |
| (...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 186 // The time when the current log was created. | 186 // The time when the current log was created. |
| 187 const base::TimeTicks creation_time_; | 187 const base::TimeTicks creation_time_; |
| 188 | 188 |
| 189 // For including information on which extensions are installed in reports. | 189 // For including information on which extensions are installed in reports. |
| 190 HashedExtensionMetrics extension_metrics_; | 190 HashedExtensionMetrics extension_metrics_; |
| 191 | 191 |
| 192 DISALLOW_COPY_AND_ASSIGN(MetricsLog); | 192 DISALLOW_COPY_AND_ASSIGN(MetricsLog); |
| 193 }; | 193 }; |
| 194 | 194 |
| 195 #endif // CHROME_BROWSER_METRICS_METRICS_LOG_H_ | 195 #endif // CHROME_BROWSER_METRICS_METRICS_LOG_H_ |
| OLD | NEW |