OLD | NEW |
---|---|
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_USER_POLICY_DISK_CACHE_H_ | 5 #ifndef CHROME_BROWSER_POLICY_USER_POLICY_DISK_CACHE_H_ |
6 #define CHROME_BROWSER_POLICY_USER_POLICY_DISK_CACHE_H_ | 6 #define CHROME_BROWSER_POLICY_USER_POLICY_DISK_CACHE_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/file_path.h" | 10 #include "base/file_path.h" |
11 #include "base/memory/ref_counted.h" | 11 #include "base/memory/ref_counted.h" |
12 #include "base/memory/weak_ptr.h" | 12 #include "base/memory/weak_ptr.h" |
13 | 13 |
14 namespace em = enterprise_management; | |
15 | |
16 namespace enterprise_management { | 14 namespace enterprise_management { |
17 class CachedCloudPolicyResponse; | 15 class CachedCloudPolicyResponse; |
pastarmovj
2011/09/20 13:14:08
Ditto space here.
Joao da Silva
2011/09/20 18:51:17
Done.
| |
18 } | 16 } |
19 | 17 |
20 namespace policy { | 18 namespace policy { |
21 | 19 |
20 namespace em = enterprise_management; | |
21 | |
22 // Handles the on-disk cache file used by UserPolicyCache. This class handles | 22 // Handles the on-disk cache file used by UserPolicyCache. This class handles |
23 // the necessary thread switching and may outlive the associated UserPolicyCache | 23 // the necessary thread switching and may outlive the associated UserPolicyCache |
24 // instance. | 24 // instance. |
25 class UserPolicyDiskCache | 25 class UserPolicyDiskCache |
26 : public base::RefCountedThreadSafe<UserPolicyDiskCache> { | 26 : public base::RefCountedThreadSafe<UserPolicyDiskCache> { |
27 public: | 27 public: |
28 // Indicates the status of a completed load operation. | 28 // Indicates the status of a completed load operation. |
29 enum LoadResult { | 29 enum LoadResult { |
30 // Policy was loaded successfully. | 30 // Policy was loaded successfully. |
31 LOAD_RESULT_SUCCESS, | 31 LOAD_RESULT_SUCCESS, |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
77 | 77 |
78 base::WeakPtr<Delegate> delegate_; | 78 base::WeakPtr<Delegate> delegate_; |
79 const FilePath backing_file_path_; | 79 const FilePath backing_file_path_; |
80 | 80 |
81 DISALLOW_COPY_AND_ASSIGN(UserPolicyDiskCache); | 81 DISALLOW_COPY_AND_ASSIGN(UserPolicyDiskCache); |
82 }; | 82 }; |
83 | 83 |
84 } // namespace policy | 84 } // namespace policy |
85 | 85 |
86 #endif // CHROME_BROWSER_POLICY_USER_POLICY_DISK_CACHE_H_ | 86 #endif // CHROME_BROWSER_POLICY_USER_POLICY_DISK_CACHE_H_ |
OLD | NEW |