1 // Copyright 2018 The Chromium Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style license that can be 3 // found in the LICENSE file. 4 5 #ifndef COMPONENTS_DOWNLOAD_PUBLIC_COMMON_DOWNLOAD_FEATURES_H_ 6 #define COMPONENTS_DOWNLOAD_PUBLIC_COMMON_DOWNLOAD_FEATURES_H_ 7 8 #include "base/feature_list.h" 9 #include "build/build_config.h" 10 #include "components/download/public/common/download_export.h" 11 12 namespace download { 13 namespace features { 14 15 // Whether offline content provider should be used for the downloads UI.. 16 COMPONENTS_DOWNLOAD_EXPORT extern const base::Feature 17 kUseDownloadOfflineContentProvider; 18 19 // Whether download auto-resumptions are enabled in native. 20 COMPONENTS_DOWNLOAD_EXPORT extern const base::Feature 21 kDownloadAutoResumptionNative; 22 23 // Whether a download can be handled by parallel jobs. 24 COMPONENTS_DOWNLOAD_EXPORT extern const base::Feature kParallelDownloading; 25 26 #if defined(OS_ANDROID) 27 // Whether download expiration date will be refreshed on resumption. 28 COMPONENTS_DOWNLOAD_EXPORT extern const base::Feature kRefreshExpirationDate; 29 #endif 30 31 // Whether in-progress download manager will be used to initialize download 32 // service. 33 COMPONENTS_DOWNLOAD_EXPORT extern const base::Feature 34 kUseInProgressDownloadManagerForDownloadService; 35 36 // Whether download resumption is allowed when there are no strong validators. 37 COMPONENTS_DOWNLOAD_EXPORT extern const base::Feature 38 kAllowDownloadResumptionWithoutStrongValidators; 39 40 // Whether parallel requests are used if server response doesn't reveal range 41 // support. 42 COMPONENTS_DOWNLOAD_EXPORT extern const base::Feature 43 kUseParallelRequestsForUnknwonRangeSupport; 44 45 // Whether parallel download is used for HTTP2 connections. 46 COMPONENTS_DOWNLOAD_EXPORT extern const base::Feature 47 kUseParallelRequestsForHTTP2; 48 49 // Whether parallel download is used for QUIC connections. 50 COMPONENTS_DOWNLOAD_EXPORT extern const base::Feature 51 kUseParallelRequestsForQUIC; 52 53 // Whether to delete expired download. 54 COMPONENTS_DOWNLOAD_EXPORT extern const base::Feature kDeleteExpiredDownloads; 55 56 } // namespace features 57 58 } // namespace download 59 60 #endif // COMPONENTS_DOWNLOAD_PUBLIC_COMMON_DOWNLOAD_FEATURES_H_ 61