| 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 service that collects information about the user | 5 // This file defines a service that collects information about the user |
| 6 // experience in order to help improve future versions of the app. | 6 // experience in order to help improve future versions of the app. |
| 7 | 7 |
| 8 #ifndef CHROME_BROWSER_METRICS_METRICS_SERVICE_H_ | 8 #ifndef CHROME_BROWSER_METRICS_METRICS_SERVICE_H_ |
| 9 #define CHROME_BROWSER_METRICS_METRICS_SERVICE_H_ | 9 #define CHROME_BROWSER_METRICS_METRICS_SERVICE_H_ |
| 10 #pragma once | 10 #pragma once |
| (...skipping 321 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 332 // Chrome OS hardware class (e.g., hardware qualification ID). This | 332 // Chrome OS hardware class (e.g., hardware qualification ID). This |
| 333 // class identifies the configured system components such as CPU, | 333 // class identifies the configured system components such as CPU, |
| 334 // WiFi adapter, etc. For non Chrome OS hosts, this will be an | 334 // WiFi adapter, etc. For non Chrome OS hosts, this will be an |
| 335 // empty string. | 335 // empty string. |
| 336 std::string hardware_class_; | 336 std::string hardware_class_; |
| 337 | 337 |
| 338 // The list of plugins which was retrieved on the file thread. | 338 // The list of plugins which was retrieved on the file thread. |
| 339 std::vector<webkit::WebPluginInfo> plugins_; | 339 std::vector<webkit::WebPluginInfo> plugins_; |
| 340 | 340 |
| 341 // The outstanding transmission appears as a URL Fetch operation. | 341 // The outstanding transmission appears as a URL Fetch operation. |
| 342 scoped_ptr<content::URLFetcher> current_fetch_; | 342 scoped_ptr<content::URLFetcher> current_fetch_xml_; |
| 343 scoped_ptr<content::URLFetcher> current_fetch_proto_; |
| 343 | 344 |
| 344 // The URL for the metrics server. | 345 // Cached responses from the XML request while we wait for a response to the |
| 345 std::wstring server_url_; | 346 // protubuf request. |
| 347 int response_code_; |
| 348 std::string response_status_; |
| 349 std::string response_data_; |
| 350 |
| 351 // The URLs for the XML and protobuf metrics servers. |
| 352 string16 server_url_xml_; |
| 353 string16 server_url_proto_; |
| 346 | 354 |
| 347 // The TCP/UDP echo server to collect network connectivity stats. | 355 // The TCP/UDP echo server to collect network connectivity stats. |
| 348 std::string network_stats_server_; | 356 std::string network_stats_server_; |
| 349 | 357 |
| 350 // The IOThread for accessing global HostResolver to resolve | 358 // The IOThread for accessing global HostResolver to resolve |
| 351 // network_stats_server_ host. |io_thread_| is accessed on IO thread and it is | 359 // network_stats_server_ host. |io_thread_| is accessed on IO thread and it is |
| 352 // safe to access it on IO thread. | 360 // safe to access it on IO thread. |
| 353 IOThread* io_thread_; | 361 IOThread* io_thread_; |
| 354 | 362 |
| 355 // The identifier that's sent to the server with the log reports. | 363 // The identifier that's sent to the server with the log reports. |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 411 friend class InstantFieldTrial; | 419 friend class InstantFieldTrial; |
| 412 friend bool prerender::IsOmniboxEnabled(Profile* profile); | 420 friend bool prerender::IsOmniboxEnabled(Profile* profile); |
| 413 | 421 |
| 414 // Returns true if prefs::kMetricsReportingEnabled is set. | 422 // Returns true if prefs::kMetricsReportingEnabled is set. |
| 415 static bool IsMetricsReportingEnabled(); | 423 static bool IsMetricsReportingEnabled(); |
| 416 | 424 |
| 417 DISALLOW_IMPLICIT_CONSTRUCTORS(MetricsServiceHelper); | 425 DISALLOW_IMPLICIT_CONSTRUCTORS(MetricsServiceHelper); |
| 418 }; | 426 }; |
| 419 | 427 |
| 420 #endif // CHROME_BROWSER_METRICS_METRICS_SERVICE_H_ | 428 #endif // CHROME_BROWSER_METRICS_METRICS_SERVICE_H_ |
| OLD | NEW |