Himanshu Jaju | dbcee23 | 2019-06-17 19:41:49 | [diff] [blame] | 1 | // Copyright 2019 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 CHROME_BROWSER_SHARING_FEATURES_H_ |
| 6 | #define CHROME_BROWSER_SHARING_FEATURES_H_ |
| 7 | |
| 8 | #include "base/feature_list.h" |
Michael van Ouwerkerk | 99d7e56 | 2019-12-03 17:14:36 | [diff] [blame] | 9 | #include "base/metrics/field_trial_params.h" |
Himanshu Jaju | dbcee23 | 2019-06-17 19:41:49 | [diff] [blame] | 10 | |
Travis Skare | ba1cc44 | 2019-10-02 22:28:11 | [diff] [blame] | 11 | // Feature flag to enable QR Code Generator (currently desktop-only). |
| 12 | extern const base::Feature kSharingQRCodeGenerator; |
| 13 | |
Michael van Ouwerkerk | 99d7e56 | 2019-12-03 17:14:36 | [diff] [blame] | 14 | // Feature flag for configuring device expiration. |
| 15 | extern const base::Feature kSharingDeviceExpiration; |
| 16 | |
| 17 | // The number of hours after which a device is considered expired. |
| 18 | extern const base::FeatureParam<int> kSharingDeviceExpirationHours; |
| 19 | |
Michael van Ouwerkerk | a91ab6e | 2020-02-03 12:55:38 | [diff] [blame] | 20 | // Feature flag for matching device expiration to pulse interval. |
| 21 | extern const base::Feature kSharingMatchPulseInterval; |
| 22 | |
| 23 | // The delta from the pulse interval in hours after which a device is considered |
| 24 | // expired, for Desktop devices. Chrome on Desktop is expected to update the |
| 25 | // last updated timestamp quite frequently because it can do this when |
| 26 | // backgrounded. Such devices can be marked stale aggressively if they did not |
| 27 | // update for more than an interval. |
| 28 | extern const base::FeatureParam<int> kSharingPulseDeltaDesktopHours; |
| 29 | |
| 30 | // The delta from the pulse interval in hours after which a device is considered |
| 31 | // expired, for Android devices. Chrome on Android is expected to update the |
| 32 | // last updated timestamp less frequently because it does not do this when |
| 33 | // backgrounded. Such devices cannot be marked stale aggressively. |
| 34 | extern const base::FeatureParam<int> kSharingPulseDeltaAndroidHours; |
| 35 | |
Michael van Ouwerkerk | 99e2ba82 | 2020-01-16 12:12:24 | [diff] [blame] | 36 | // Feature flag for configuring the sharing message timeout. This sets both the |
| 37 | // FCM message TTL and the duration of the timer that waits for an ack. |
| 38 | extern const base::Feature kSharingMessageTTL; |
| 39 | |
| 40 | // The duration in seconds for both the FCM message TTL and the timer that waits |
| 41 | // for an ack. |
| 42 | extern const base::FeatureParam<int> kSharingMessageTTLSeconds; |
| 43 | |
| 44 | // Feature flag for configuring the FCM TTL for sharing ack messages. |
| 45 | extern const base::Feature kSharingAckMessageTTL; |
| 46 | |
| 47 | // The FCM TTL in seconds for sharing ack messages. |
| 48 | extern const base::FeatureParam<int> kSharingAckMessageTTLSeconds; |
| 49 | |
Rushan Suleymanov | 53b3f05 | 2020-03-05 09:22:31 | [diff] [blame] | 50 | // Feature flag for configuring the timeout in the sharing message bridge. |
| 51 | extern const base::Feature kSharingMessageBridgeTimeout; |
| 52 | extern const base::FeatureParam<int> kSharingMessageBridgeTimeoutSeconds; |
| 53 | |
Alex Chau | f15a719 | 2020-01-30 17:37:51 | [diff] [blame] | 54 | // Feature flag for sending sharing message via Sync. |
| 55 | extern const base::Feature kSharingSendViaSync; |
| 56 | |
Alex Chau | d788684 | 2020-05-13 15:37:05 | [diff] [blame^] | 57 | // Feature flag for prefer sending sharing message using VAPID. |
| 58 | extern const base::Feature kSharingPreferVapid; |
| 59 | |
Himanshu Jaju | dbcee23 | 2019-06-17 19:41:49 | [diff] [blame] | 60 | #endif // CHROME_BROWSER_SHARING_FEATURES_H_ |