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 // Holds helpers for gathering UMA stats about downloads. | 5 // Holds helpers for gathering UMA stats about downloads. |
6 | 6 |
7 #ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_STATS_H_ | 7 #ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_STATS_H_ |
8 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_STATS_H_ | 8 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_STATS_H_ |
9 | 9 |
10 #include <stddef.h> | 10 #include <stddef.h> |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
84 | 84 |
85 // Count of downloads that didn't have a valid WebContents at the time it was | 85 // Count of downloads that didn't have a valid WebContents at the time it was |
86 // interrupted. | 86 // interrupted. |
87 INTERRUPTED_WITHOUT_WEBCONTENTS, | 87 INTERRUPTED_WITHOUT_WEBCONTENTS, |
88 | 88 |
89 // Count of downloads that supplies a strong validator (implying byte-wise | 89 // Count of downloads that supplies a strong validator (implying byte-wise |
90 // equivalence) and has a 'Accept-Ranges: bytes' header. These downloads are | 90 // equivalence) and has a 'Accept-Ranges: bytes' header. These downloads are |
91 // candidates for partial resumption. | 91 // candidates for partial resumption. |
92 STRONG_VALIDATOR_AND_ACCEPTS_RANGES, | 92 STRONG_VALIDATOR_AND_ACCEPTS_RANGES, |
93 | 93 |
| 94 // Count of downloads that uses parallel download requests. |
| 95 USES_PARALLEL_REQUESTS, |
| 96 |
94 DOWNLOAD_COUNT_TYPES_LAST_ENTRY | 97 DOWNLOAD_COUNT_TYPES_LAST_ENTRY |
95 }; | 98 }; |
96 | 99 |
97 enum DownloadSource { | 100 enum DownloadSource { |
98 // The download was initiated when the SavePackage system rejected | 101 // The download was initiated when the SavePackage system rejected |
99 // a Save Page As ... by returning false from | 102 // a Save Page As ... by returning false from |
100 // SavePackage::IsSaveableContents(). | 103 // SavePackage::IsSaveableContents(). |
101 INITIATED_BY_SAVE_PACKAGE_ON_NON_HTML = 0, | 104 INITIATED_BY_SAVE_PACKAGE_ON_NON_HTML = 0, |
102 | 105 |
103 // The download was initiated by a drag and drop from a drag-and-drop | 106 // The download was initiated by a drag and drop from a drag-and-drop |
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
251 | 254 |
252 void RecordDownloadConnectionSecurity(const GURL& download_url, | 255 void RecordDownloadConnectionSecurity(const GURL& download_url, |
253 const std::vector<GURL>& url_chain); | 256 const std::vector<GURL>& url_chain); |
254 | 257 |
255 void RecordDownloadSourcePageTransitionType( | 258 void RecordDownloadSourcePageTransitionType( |
256 const base::Optional<ui::PageTransition>& transition); | 259 const base::Optional<ui::PageTransition>& transition); |
257 | 260 |
258 } // namespace content | 261 } // namespace content |
259 | 262 |
260 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_STATS_H_ | 263 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_STATS_H_ |
OLD | NEW |