OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CHROME_BROWSER_POLICY_CLOUD_CLOUD_POLICY_REFRESH_SCHEDULER_H_ | 5 #ifndef CHROME_BROWSER_POLICY_CLOUD_CLOUD_POLICY_REFRESH_SCHEDULER_H_ |
6 #define CHROME_BROWSER_POLICY_CLOUD_CLOUD_POLICY_REFRESH_SCHEDULER_H_ | 6 #define CHROME_BROWSER_POLICY_CLOUD_CLOUD_POLICY_REFRESH_SCHEDULER_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/cancelable_callback.h" | 9 #include "base/cancelable_callback.h" |
10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
50 // Sets the refresh delay to |refresh_delay| (subject to min/max clamping). | 50 // Sets the refresh delay to |refresh_delay| (subject to min/max clamping). |
51 void SetRefreshDelay(int64 refresh_delay); | 51 void SetRefreshDelay(int64 refresh_delay); |
52 | 52 |
53 // Requests a policy refresh to be performed soon. This may apply throttling, | 53 // Requests a policy refresh to be performed soon. This may apply throttling, |
54 // and the request may not be immediately sent. | 54 // and the request may not be immediately sent. |
55 void RefreshSoon(); | 55 void RefreshSoon(); |
56 | 56 |
57 // CloudPolicyClient::Observer: | 57 // CloudPolicyClient::Observer: |
58 virtual void OnPolicyFetched(CloudPolicyClient* client) OVERRIDE; | 58 virtual void OnPolicyFetched(CloudPolicyClient* client) OVERRIDE; |
59 virtual void OnRegistrationStateChanged(CloudPolicyClient* client) OVERRIDE; | 59 virtual void OnRegistrationStateChanged(CloudPolicyClient* client) OVERRIDE; |
| 60 virtual void OnRobotAuthCodesFetched(CloudPolicyClient* client) OVERRIDE; |
60 virtual void OnClientError(CloudPolicyClient* client) OVERRIDE; | 61 virtual void OnClientError(CloudPolicyClient* client) OVERRIDE; |
61 | 62 |
62 // CloudPolicyStore::Observer: | 63 // CloudPolicyStore::Observer: |
63 virtual void OnStoreLoaded(CloudPolicyStore* store) OVERRIDE; | 64 virtual void OnStoreLoaded(CloudPolicyStore* store) OVERRIDE; |
64 virtual void OnStoreError(CloudPolicyStore* store) OVERRIDE; | 65 virtual void OnStoreError(CloudPolicyStore* store) OVERRIDE; |
65 | 66 |
66 // net::NetworkChangeNotifier::IPAddressObserver: | 67 // net::NetworkChangeNotifier::IPAddressObserver: |
67 virtual void OnIPAddressChanged() OVERRIDE; | 68 virtual void OnIPAddressChanged() OVERRIDE; |
68 | 69 |
69 private: | 70 private: |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
108 | 109 |
109 // Used to limit the rate at which refreshes are scheduled. | 110 // Used to limit the rate at which refreshes are scheduled. |
110 RateLimiter rate_limiter_; | 111 RateLimiter rate_limiter_; |
111 | 112 |
112 DISALLOW_COPY_AND_ASSIGN(CloudPolicyRefreshScheduler); | 113 DISALLOW_COPY_AND_ASSIGN(CloudPolicyRefreshScheduler); |
113 }; | 114 }; |
114 | 115 |
115 } // namespace policy | 116 } // namespace policy |
116 | 117 |
117 #endif // CHROME_BROWSER_POLICY_CLOUD_CLOUD_POLICY_REFRESH_SCHEDULER_H_ | 118 #endif // CHROME_BROWSER_POLICY_CLOUD_CLOUD_POLICY_REFRESH_SCHEDULER_H_ |
OLD | NEW |