Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(548)

Unified Diff: components/policy/core/common/cloud/cloud_policy_refresh_scheduler.h

Issue 2159223002: Fixed cloud policy refresh API to return correct value. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review feedback Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/policy/core/common/cloud/cloud_policy_refresh_scheduler.h
diff --git a/components/policy/core/common/cloud/cloud_policy_refresh_scheduler.h b/components/policy/core/common/cloud/cloud_policy_refresh_scheduler.h
index 30fee43a0c15a3df9946b92675a5d3f8033beb6f..fc1a2edd9f8651a081afc5b00499f0a789da5664 100644
--- a/components/policy/core/common/cloud/cloud_policy_refresh_scheduler.h
+++ b/components/policy/core/common/cloud/cloud_policy_refresh_scheduler.h
@@ -48,10 +48,14 @@ class POLICY_EXPORT CloudPolicyRefreshScheduler
~CloudPolicyRefreshScheduler() override;
base::Time last_refresh() const { return last_refresh_; }
- int64_t refresh_delay() const { return refresh_delay_ms_; }
- // Sets the refresh delay to |refresh_delay| (subject to min/max clamping).
- void SetRefreshDelay(int64_t refresh_delay);
+ // Sets the refresh delay to |refresh_delay| (actual refresh delay may vary
+ // due to min/max clamping, changes to delay due to invalidations, etc).
+ void SetDesiredRefreshDelay(int64_t refresh_delay);
+
+ // Returns the current fixed refresh delay (can vary depending on whether
+ // invalidations are available or not).
+ int64_t GetActualRefreshDelay() const;
// Requests a policy refresh to be performed soon.
void RefreshSoon();

Powered by Google App Engine
This is Rietveld 408576698