Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef CHROME_BROWSER_PREFS_TRACKED_TRACKED_PREFERENCE_VALIDATION_OBSERVER_H_ | |
| 6 #define CHROME_BROWSER_PREFS_TRACKED_TRACKED_PREFERENCE_VALIDATION_OBSERVER_H_ | |
| 7 | |
| 8 #include <string> | |
| 9 #include <vector> | |
| 10 | |
| 11 #include "chrome/browser/prefs/pref_hash_store_transaction.h" | |
| 12 #include "chrome/browser/prefs/tracked/tracked_preference_helper.h" | |
| 13 | |
| 14 namespace base { | |
| 15 class DictionaryValue; | |
| 16 class Value; | |
| 17 } | |
| 18 | |
| 19 // A TrackedPreferenceValidationObserver is notified of the results of each | |
| 20 // tracked preference validation event. | |
| 21 class TrackedPreferenceValidationObserver { | |
| 22 public: | |
| 23 virtual ~TrackedPreferenceValidationObserver() {} | |
| 24 | |
| 25 // Notifies observes of the result (|value_state|) of checking the atomic | |
| 26 // |value| at |pref_path|. |reset_action| indicates whether or not a reset is | |
| 27 // desired based on |value_state| and the enforcement level in place. | |
|
erikwright (departed)
2014/05/14 00:39:26
is desired -> will occur.
grt (UTC plus 2)
2014/05/14 18:57:22
Done.
| |
| 28 virtual void OnAtomicPreferenceValidation( | |
| 29 const std::string& pref_path, | |
| 30 const base::Value* value, | |
| 31 PrefHashStoreTransaction::ValueState value_state, | |
| 32 TrackedPreferenceHelper::ResetAction reset_action) = 0; | |
| 33 | |
| 34 // Notifies observes of the result (|value_state|) of checking the split | |
| 35 // |dict_value| at |pref_path|. |reset_action| indicates whether or not a | |
| 36 // reset of |value_keys| is desired based on |value_state| and the enforcement | |
|
erikwright (departed)
2014/05/14 00:39:26
ditto.
grt (UTC plus 2)
2014/05/14 18:57:22
Done.
| |
| 37 // level in place. | |
| 38 virtual void OnSplitPreferenceValidation( | |
| 39 const std::string& pref_path, | |
| 40 const base::DictionaryValue* dict_value, | |
| 41 const std::vector<std::string>& invalid_keys, | |
| 42 PrefHashStoreTransaction::ValueState value_state, | |
| 43 TrackedPreferenceHelper::ResetAction reset_action) = 0; | |
| 44 }; | |
| 45 | |
| 46 #endif // CHROME_BROWSER_PREFS_TRACKED_TRACKED_PREFERENCE_VALIDATION_OBSERVER_H _ | |
| OLD | NEW |