| Index: components/policy/core/common/policy_map.h
|
| diff --git a/components/policy/core/common/policy_map.h b/components/policy/core/common/policy_map.h
|
| index 7d0d06b80b4ba35e13154726b2dabd17d7e86a43..8480e2ff20eb0a0cf2b2c3ef3fa12c1bee82e37e 100644
|
| --- a/components/policy/core/common/policy_map.h
|
| +++ b/components/policy/core/common/policy_map.h
|
| @@ -28,6 +28,9 @@ class POLICY_EXPORT PolicyMap {
|
| base::Value* value;
|
| ExternalDataFetcher* external_data_fetcher;
|
|
|
| + // For debugging and displaying only. Set by provider delivering the policy.
|
| + PolicySource source;
|
| +
|
| Entry();
|
|
|
| // Deletes all members owned by |this|.
|
| @@ -58,14 +61,25 @@ class POLICY_EXPORT PolicyMap {
|
| // This is equivalent to Get(policy)->value, when it doesn't return NULL.
|
| const base::Value* GetValue(const std::string& policy) const;
|
|
|
| - // Takes ownership of |value| and |external_data_fetcher|. Overwrites any
|
| - // existing information stored in the map for the key |policy|.
|
| + // Sets the source of every Entry in the Map to the passed |source|.
|
| + void SetEntrySources(PolicySource source);
|
| +
|
| + // Calls |SetWithSource| with default source.
|
| void Set(const std::string& policy,
|
| PolicyLevel level,
|
| PolicyScope scope,
|
| base::Value* value,
|
| ExternalDataFetcher* external_data_fetcher);
|
|
|
| + // Takes ownership of |value| and |external_data_fetcher|. Overwrites any
|
| + // existing information stored in the map for the key |policy|.
|
| + void SetWithSource(const std::string& policy,
|
| + PolicyLevel level,
|
| + PolicyScope scope,
|
| + base::Value* value,
|
| + ExternalDataFetcher* external_data_fetcher,
|
| + PolicySource source);
|
| +
|
| // Erase the given |policy|, if it exists in this map.
|
| void Erase(const std::string& policy);
|
|
|
|
|