| 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 COMPONENTS_POLICY_CORE_COMMON_CLOUD_CLOUD_POLICY_CLIENT_H_ | 5 #ifndef COMPONENTS_POLICY_CORE_COMMON_CLOUD_CLOUD_POLICY_CLIENT_H_ |
| 6 #define COMPONENTS_POLICY_CORE_COMMON_CLOUD_CLOUD_POLICY_CLIENT_H_ | 6 #define COMPONENTS_POLICY_CORE_COMMON_CLOUD_CLOUD_POLICY_CLIENT_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <map> | 10 #include <map> |
| (...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 214 // Removes the specified observer. | 214 // Removes the specified observer. |
| 215 void RemoveObserver(Observer* observer); | 215 void RemoveObserver(Observer* observer); |
| 216 | 216 |
| 217 const std::string& machine_id() const { return machine_id_; } | 217 const std::string& machine_id() const { return machine_id_; } |
| 218 const std::string& machine_model() const { return machine_model_; } | 218 const std::string& machine_model() const { return machine_model_; } |
| 219 | 219 |
| 220 void set_last_policy_timestamp(const base::Time& timestamp) { | 220 void set_last_policy_timestamp(const base::Time& timestamp) { |
| 221 last_policy_timestamp_ = timestamp; | 221 last_policy_timestamp_ = timestamp; |
| 222 } | 222 } |
| 223 | 223 |
| 224 const base::Time& last_policy_timestamp() { return last_policy_timestamp_; } |
| 225 |
| 224 void set_public_key_version(int public_key_version) { | 226 void set_public_key_version(int public_key_version) { |
| 225 public_key_version_ = public_key_version; | 227 public_key_version_ = public_key_version; |
| 226 public_key_version_valid_ = true; | 228 public_key_version_valid_ = true; |
| 227 } | 229 } |
| 228 | 230 |
| 229 void clear_public_key_version() { | 231 void clear_public_key_version() { |
| 230 public_key_version_valid_ = false; | 232 public_key_version_valid_ = false; |
| 231 } | 233 } |
| 232 | 234 |
| 233 // FetchPolicy() calls will request this policy type. | 235 // FetchPolicy() calls will request this policy type. |
| (...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 436 | 438 |
| 437 // Used to create tasks which run delayed on the UI thread. | 439 // Used to create tasks which run delayed on the UI thread. |
| 438 base::WeakPtrFactory<CloudPolicyClient> weak_ptr_factory_; | 440 base::WeakPtrFactory<CloudPolicyClient> weak_ptr_factory_; |
| 439 | 441 |
| 440 DISALLOW_COPY_AND_ASSIGN(CloudPolicyClient); | 442 DISALLOW_COPY_AND_ASSIGN(CloudPolicyClient); |
| 441 }; | 443 }; |
| 442 | 444 |
| 443 } // namespace policy | 445 } // namespace policy |
| 444 | 446 |
| 445 #endif // COMPONENTS_POLICY_CORE_COMMON_CLOUD_CLOUD_POLICY_CLIENT_H_ | 447 #endif // COMPONENTS_POLICY_CORE_COMMON_CLOUD_CLOUD_POLICY_CLIENT_H_ |
| OLD | NEW |