Chromium Code Reviews| 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_DATA_USE_MEASUREMENT_CHROME_DATA_USE_ASCRIBER_H_ | 5 #ifndef CHROME_BROWSER_DATA_USE_MEASUREMENT_CHROME_DATA_USE_ASCRIBER_H_ |
| 6 #define CHROME_BROWSER_DATA_USE_MEASUREMENT_CHROME_DATA_USE_ASCRIBER_H_ | 6 #define CHROME_BROWSER_DATA_USE_MEASUREMENT_CHROME_DATA_USE_ASCRIBER_H_ |
| 7 | 7 |
| 8 #include <memory> | |
| 9 | |
| 8 #include "base/macros.h" | 10 #include "base/macros.h" |
| 9 #include "components/data_use_measurement/core/data_use_ascriber.h" | 11 #include "components/data_use_measurement/core/data_use_ascriber.h" |
| 10 #include "url/gurl.h" | 12 #include "url/gurl.h" |
| 11 | 13 |
| 12 namespace content { | 14 namespace content { |
| 13 class NavigationHandle; | 15 class NavigationHandle; |
| 14 class RenderFrameHost; | 16 class RenderFrameHost; |
| 15 } | 17 } |
| 16 | 18 |
| 17 namespace data_use_measurement { | 19 namespace data_use_measurement { |
| 18 | 20 |
| 21 class URLRequestClassifier; | |
| 22 | |
| 19 // Browser implementation of DataUseAscriber. Maintains a list of | 23 // Browser implementation of DataUseAscriber. Maintains a list of |
| 20 // DataUseRecorder instances, one for each source of data, such as a page | 24 // DataUseRecorder instances, one for each source of data, such as a page |
| 21 // load. | 25 // load. |
| 22 // | 26 // |
| 23 // A page includes all resources loaded in response to a main page navigation. | 27 // A page includes all resources loaded in response to a main page navigation. |
| 24 // The scope of a page load ends either when the tab is closed or a new page | 28 // The scope of a page load ends either when the tab is closed or a new page |
| 25 // load is initiated by clicking on a link, entering a new URL, window location | 29 // load is initiated by clicking on a link, entering a new URL, window location |
| 26 // change, etc. | 30 // change, etc. |
| 27 // | 31 // |
| 28 // For URLRequests initiated outside the context of a page load, such as | 32 // For URLRequests initiated outside the context of a page load, such as |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 68 int render_frame_id, | 72 int render_frame_id, |
| 69 bool is_same_page_navigation, | 73 bool is_same_page_navigation, |
| 70 void* navigation_handle); | 74 void* navigation_handle); |
| 71 | 75 |
| 72 // Called when a main frame navigation is redirected. | 76 // Called when a main frame navigation is redirected. |
| 73 void DidRedirectMainFrameNavigation(GURL gurl, | 77 void DidRedirectMainFrameNavigation(GURL gurl, |
| 74 int render_process_id, | 78 int render_process_id, |
| 75 int render_frame_id, | 79 int render_frame_id, |
| 76 void* navigation_handle); | 80 void* navigation_handle); |
| 77 | 81 |
| 82 std::unique_ptr<URLRequestClassifier> CreateURLRequestClassifier() | |
| 83 const override; | |
|
Not at Google. Contact bengr
2016/11/11 00:09:48
Move above to be with the other overridden method.
Raj
2016/11/11 19:10:39
Done.
| |
| 84 | |
| 78 private: | 85 private: |
| 79 DISALLOW_COPY_AND_ASSIGN(ChromeDataUseAscriber); | 86 DISALLOW_COPY_AND_ASSIGN(ChromeDataUseAscriber); |
| 80 }; | 87 }; |
| 81 | 88 |
| 82 } // namespace data_use_measurement | 89 } // namespace data_use_measurement |
| 83 | 90 |
| 84 #endif // CHROME_BROWSER_DATA_USE_MEASUREMENT_CHROME_DATA_USE_ASCRIBER_H_ | 91 #endif // CHROME_BROWSER_DATA_USE_MEASUREMENT_CHROME_DATA_USE_ASCRIBER_H_ |
| OLD | NEW |