| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_METRICS_CHROME_METRICS_SERVICE_CLIENT_H_ | 5 #ifndef CHROME_BROWSER_METRICS_CHROME_METRICS_SERVICE_CLIENT_H_ |
| 6 #define CHROME_BROWSER_METRICS_CHROME_METRICS_SERVICE_CLIENT_H_ | 6 #define CHROME_BROWSER_METRICS_CHROME_METRICS_SERVICE_CLIENT_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 61 int32 GetProduct() override; | 61 int32 GetProduct() override; |
| 62 std::string GetApplicationLocale() override; | 62 std::string GetApplicationLocale() override; |
| 63 bool GetBrand(std::string* brand_code) override; | 63 bool GetBrand(std::string* brand_code) override; |
| 64 metrics::SystemProfileProto::Channel GetChannel() override; | 64 metrics::SystemProfileProto::Channel GetChannel() override; |
| 65 std::string GetVersionString() override; | 65 std::string GetVersionString() override; |
| 66 void OnLogUploadComplete() override; | 66 void OnLogUploadComplete() override; |
| 67 void StartGatheringMetrics(const base::Closure& done_callback) override; | 67 void StartGatheringMetrics(const base::Closure& done_callback) override; |
| 68 void CollectFinalMetrics(const base::Closure& done_callback) override; | 68 void CollectFinalMetrics(const base::Closure& done_callback) override; |
| 69 scoped_ptr<metrics::MetricsLogUploader> CreateUploader( | 69 scoped_ptr<metrics::MetricsLogUploader> CreateUploader( |
| 70 const base::Callback<void(int)>& on_upload_complete) override; | 70 const base::Callback<void(int)>& on_upload_complete) override; |
| 71 base::TimeDelta GetStandardUploadInterval() override; |
| 71 base::string16 GetRegistryBackupKey() override; | 72 base::string16 GetRegistryBackupKey() override; |
| 72 | 73 |
| 73 metrics::MetricsService* metrics_service() { return metrics_service_.get(); } | 74 metrics::MetricsService* metrics_service() { return metrics_service_.get(); } |
| 74 | 75 |
| 75 void LogPluginLoadingError(const base::FilePath& plugin_path); | 76 void LogPluginLoadingError(const base::FilePath& plugin_path); |
| 76 | 77 |
| 77 private: | 78 private: |
| 78 explicit ChromeMetricsServiceClient( | 79 explicit ChromeMetricsServiceClient( |
| 79 metrics::MetricsStateManager* state_manager); | 80 metrics::MetricsStateManager* state_manager); |
| 80 | 81 |
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 164 GoogleUpdateMetricsProviderWin* google_update_metrics_provider_; | 165 GoogleUpdateMetricsProviderWin* google_update_metrics_provider_; |
| 165 #endif | 166 #endif |
| 166 | 167 |
| 167 // Callback that is called when initial metrics gathering is complete. | 168 // Callback that is called when initial metrics gathering is complete. |
| 168 base::Closure finished_gathering_initial_metrics_callback_; | 169 base::Closure finished_gathering_initial_metrics_callback_; |
| 169 | 170 |
| 170 // The MemoryGrowthTracker instance that tracks memory usage growth in | 171 // The MemoryGrowthTracker instance that tracks memory usage growth in |
| 171 // MemoryDetails. | 172 // MemoryDetails. |
| 172 MemoryGrowthTracker memory_growth_tracker_; | 173 MemoryGrowthTracker memory_growth_tracker_; |
| 173 | 174 |
| 175 // Callback to determine whether or not a cellular network is currently being |
| 176 // used. |
| 177 base::Callback<void(bool*)> cellular_callback_; |
| 178 |
| 174 base::WeakPtrFactory<ChromeMetricsServiceClient> weak_ptr_factory_; | 179 base::WeakPtrFactory<ChromeMetricsServiceClient> weak_ptr_factory_; |
| 175 | 180 |
| 176 DISALLOW_COPY_AND_ASSIGN(ChromeMetricsServiceClient); | 181 DISALLOW_COPY_AND_ASSIGN(ChromeMetricsServiceClient); |
| 177 }; | 182 }; |
| 178 | 183 |
| 179 #endif // CHROME_BROWSER_METRICS_CHROME_METRICS_SERVICE_CLIENT_H_ | 184 #endif // CHROME_BROWSER_METRICS_CHROME_METRICS_SERVICE_CLIENT_H_ |
| OLD | NEW |