| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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_LOFI_DECIDER_H_ | 5 #ifndef COMPONENTS_DATA_REDUCTION_PROXY_CORE_BROWSER_LOFI_DECIDER_H_ |
| 6 #define COMPONENTS_DATA_REDUCTION_PROXY_CORE_BROWSER_LOFI_DECIDER_H_ | 6 #define COMPONENTS_DATA_REDUCTION_PROXY_CORE_BROWSER_LOFI_DECIDER_H_ |
| 7 | 7 |
| 8 #include "base/macros.h" | 8 #include "base/macros.h" |
| 9 | 9 |
| 10 namespace net { | 10 namespace net { |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 56 | 56 |
| 57 // Adds a directive to tell the server to ignore blacklists when a Lite Page | 57 // Adds a directive to tell the server to ignore blacklists when a Lite Page |
| 58 // preview is being requested due to command line flags being set. | 58 // preview is being requested due to command line flags being set. |
| 59 virtual void MaybeSetIgnorePreviewsBlacklistDirective( | 59 virtual void MaybeSetIgnorePreviewsBlacklistDirective( |
| 60 net::HttpRequestHeaders* headers) const = 0; | 60 net::HttpRequestHeaders* headers) const = 0; |
| 61 | 61 |
| 62 // Returns true if the Lo-Fi specific UMA should be recorded. It is set to | 62 // Returns true if the Lo-Fi specific UMA should be recorded. It is set to |
| 63 // true if Lo-Fi is enabled for |request|, Chrome session is in Lo-Fi | 63 // true if Lo-Fi is enabled for |request|, Chrome session is in Lo-Fi |
| 64 // Enabled or Control field trial, and the network quality was slow. | 64 // Enabled or Control field trial, and the network quality was slow. |
| 65 virtual bool ShouldRecordLoFiUMA(const net::URLRequest& request) const = 0; | 65 virtual bool ShouldRecordLoFiUMA(const net::URLRequest& request) const = 0; |
| 66 |
| 67 // Returns whether the request was a client-side Lo-Fi image request. |
| 68 virtual bool IsClientLoFiImageRequest( |
| 69 const net::URLRequest& request) const = 0; |
| 66 }; | 70 }; |
| 67 | 71 |
| 68 } // namespace data_reduction_proxy | 72 } // namespace data_reduction_proxy |
| 69 | 73 |
| 70 #endif // COMPONENTS_DATA_REDUCTION_PROXY_CORE_BROWSER_LOFI_DECIDER_H_ | 74 #endif // COMPONENTS_DATA_REDUCTION_PROXY_CORE_BROWSER_LOFI_DECIDER_H_ |
| OLD | NEW |