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 COMPONENTS_DATA_REDUCTION_PROXY_CORE_BROWSER_DATA_REDUCTION_PROXY_METRIC
S_H_ | 5 #ifndef COMPONENTS_DATA_REDUCTION_PROXY_CORE_BROWSER_DATA_REDUCTION_PROXY_METRIC
S_H_ |
6 #define COMPONENTS_DATA_REDUCTION_PROXY_CORE_BROWSER_DATA_REDUCTION_PROXY_METRIC
S_H_ | 6 #define COMPONENTS_DATA_REDUCTION_PROXY_CORE_BROWSER_DATA_REDUCTION_PROXY_METRIC
S_H_ |
7 | 7 |
8 #include "base/time/time.h" | 8 #include "base/time/time.h" |
9 | 9 |
10 namespace net { | 10 namespace net { |
11 class ProxyConfig; | 11 class ProxyConfig; |
12 class URLRequest; | 12 class URLRequest; |
13 } | 13 } |
14 | 14 |
15 class PrefService; | 15 class PrefService; |
16 | 16 |
17 namespace data_reduction_proxy { | 17 namespace data_reduction_proxy { |
18 | 18 |
19 class DataReductionProxyConfig; | 19 class DataReductionProxyConfig; |
20 class DataReductionProxyStatisticsPrefs; | 20 class DataReductionProxyCompressionStats; |
21 | 21 |
22 enum DataReductionProxyRequestType { | 22 enum DataReductionProxyRequestType { |
23 VIA_DATA_REDUCTION_PROXY, // A request served by the data reduction proxy. | 23 VIA_DATA_REDUCTION_PROXY, // A request served by the data reduction proxy. |
24 | 24 |
25 // Below are reasons why a request is not served by the enabled data reduction | 25 // Below are reasons why a request is not served by the enabled data reduction |
26 // proxy. Off-the-record profile data is not counted in all cases. | 26 // proxy. Off-the-record profile data is not counted in all cases. |
27 HTTPS, // An https request. | 27 HTTPS, // An https request. |
28 SHORT_BYPASS, // The client is bypassed by the proxy for a short time. | 28 SHORT_BYPASS, // The client is bypassed by the proxy for a short time. |
29 LONG_BYPASS, // The client is bypassed by the proxy for a long time (due | 29 LONG_BYPASS, // The client is bypassed by the proxy for a long time (due |
30 // to country bypass policy, for example). | 30 // to country bypass policy, for example). |
(...skipping 15 matching lines...) Expand all Loading... |
46 int64 received_content_length); | 46 int64 received_content_length); |
47 | 47 |
48 // This is only exposed for testing. It is normally called by | 48 // This is only exposed for testing. It is normally called by |
49 // UpdateContentLengthPrefs. | 49 // UpdateContentLengthPrefs. |
50 void UpdateContentLengthPrefsForDataReductionProxy( | 50 void UpdateContentLengthPrefsForDataReductionProxy( |
51 int received_content_length, | 51 int received_content_length, |
52 int original_content_length, | 52 int original_content_length, |
53 bool with_data_reduction_proxy_enabled, | 53 bool with_data_reduction_proxy_enabled, |
54 DataReductionProxyRequestType request_type, | 54 DataReductionProxyRequestType request_type, |
55 base::Time now, | 55 base::Time now, |
56 DataReductionProxyStatisticsPrefs* prefs); | 56 DataReductionProxyCompressionStats* compression_stats); |
57 | 57 |
58 } // namespace data_reduction_proxy | 58 } // namespace data_reduction_proxy |
59 | 59 |
60 #endif // COMPONENTS_DATA_REDUCTION_PROXY_CORE_BROWSER_DATA_REDUCTION_PROXY_MET
RICS_H_ | 60 #endif // COMPONENTS_DATA_REDUCTION_PROXY_CORE_BROWSER_DATA_REDUCTION_PROXY_MET
RICS_H_ |
OLD | NEW |