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_CONFIG_DIR_POLICY_LOADER_H_ | 5 #ifndef COMPONENTS_POLICY_CORE_COMMON_CONFIG_DIR_POLICY_LOADER_H_ |
6 #define COMPONENTS_POLICY_CORE_COMMON_CONFIG_DIR_POLICY_LOADER_H_ | 6 #define COMPONENTS_POLICY_CORE_COMMON_CONFIG_DIR_POLICY_LOADER_H_ |
7 | 7 |
8 #include "base/files/file_path.h" | 8 #include "base/files/file_path.h" |
9 #include "base/files/file_path_watcher.h" | 9 #include "base/files/file_path_watcher.h" |
10 #include "components/policy/core/common/async_policy_loader.h" | 10 #include "components/policy/core/common/async_policy_loader.h" |
(...skipping 15 matching lines...) Expand all Loading... | |
26 public: | 26 public: |
27 ConfigDirPolicyLoader(scoped_refptr<base::SequencedTaskRunner> task_runner, | 27 ConfigDirPolicyLoader(scoped_refptr<base::SequencedTaskRunner> task_runner, |
28 const base::FilePath& config_dir, | 28 const base::FilePath& config_dir, |
29 PolicyScope scope); | 29 PolicyScope scope); |
30 ~ConfigDirPolicyLoader() override; | 30 ~ConfigDirPolicyLoader() override; |
31 | 31 |
32 // AsyncPolicyLoader implementation. | 32 // AsyncPolicyLoader implementation. |
33 void InitOnBackgroundThread() override; | 33 void InitOnBackgroundThread() override; |
34 scoped_ptr<PolicyBundle> Load() override; | 34 scoped_ptr<PolicyBundle> Load() override; |
35 base::Time LastModificationTime() override; | 35 base::Time LastModificationTime() override; |
36 // ConfigurationPolicyProvider::source() now indicates provided sources are | |
Thiemo Nagel
2015/09/01 17:40:37
Remove.
fhorschig
2015/09/04 06:53:54
Done.
| |
37 // originating from a local platform. | |
38 PolicySource source() const override; | |
36 | 39 |
37 private: | 40 private: |
38 // Loads the policy files at |path| into the |bundle|, with the given |level|. | 41 // Loads the policy files at |path| into the |bundle|, with the given |level|. |
39 void LoadFromPath(const base::FilePath& path, | 42 void LoadFromPath(const base::FilePath& path, |
40 PolicyLevel level, | 43 PolicyLevel level, |
41 PolicyBundle* bundle); | 44 PolicyBundle* bundle); |
42 | 45 |
43 // Merges the 3rd party |policies| into the |bundle|, with the given |level|. | 46 // Merges the 3rd party |policies| into the |bundle|, with the given |level|. |
44 void Merge3rdPartyPolicy(const base::Value* policies, | 47 void Merge3rdPartyPolicy(const base::Value* policies, |
45 PolicyLevel level, | 48 PolicyLevel level, |
(...skipping 12 matching lines...) Expand all Loading... | |
58 // |config_dir_|. | 61 // |config_dir_|. |
59 base::FilePathWatcher mandatory_watcher_; | 62 base::FilePathWatcher mandatory_watcher_; |
60 base::FilePathWatcher recommended_watcher_; | 63 base::FilePathWatcher recommended_watcher_; |
61 | 64 |
62 DISALLOW_COPY_AND_ASSIGN(ConfigDirPolicyLoader); | 65 DISALLOW_COPY_AND_ASSIGN(ConfigDirPolicyLoader); |
63 }; | 66 }; |
64 | 67 |
65 } // namespace policy | 68 } // namespace policy |
66 | 69 |
67 #endif // COMPONENTS_POLICY_CORE_COMMON_CONFIG_DIR_POLICY_LOADER_H_ | 70 #endif // COMPONENTS_POLICY_CORE_COMMON_CONFIG_DIR_POLICY_LOADER_H_ |
OLD | NEW |