#include "components/performance_manager/public/user_tuning/prefs.h"
#include <iterator>
#include <optional>
#include <string>
#include <utility>
#include <vector>
#include "base/check.h"
#include "base/containers/contains.h"
#include "base/json/values_util.h"
#include "base/values.h"
#include "components/pref_registry/pref_registry_syncable.h"
#include "components/prefs/pref_registry_simple.h"
#include "components/prefs/pref_service.h"
namespace performance_manager::user_tuning::prefs {
void RegisterLocalStatePrefs(PrefRegistrySimple* registry) { … }
void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry) { … }
MemorySaverModeState GetCurrentMemorySaverModeState(PrefService* pref_service) { … }
MemorySaverModeAggressiveness GetCurrentMemorySaverMode(
PrefService* pref_service) { … }
base::TimeDelta GetCurrentMemorySaverModeTimeBeforeDiscard(
PrefService* pref_service) { … }
BatterySaverModeState GetCurrentBatterySaverModeState(
PrefService* pref_service) { … }
bool ShouldShowDiscardRingTreatment(PrefService* pref_service) { … }
bool ShouldShowPerformanceInterventionNotification(PrefService* pref_service) { … }
void MigrateMemorySaverModePref(PrefService* pref_service) { … }
void MigrateMultiStateMemorySaverModePref(PrefService* pref_service) { … }
void MigrateTabDiscardingExceptionsPref(PrefService* pref_service) { … }
bool IsSiteInTabDiscardExceptionsList(PrefService* pref_service,
const std::string& site) { … }
void AddSiteToTabDiscardExceptionsList(PrefService* pref_service,
const std::string& site) { … }
std::vector<std::string> GetTabDiscardExceptionsBetween(
PrefService* pref_service,
base::Time period_start,
base::Time period_end) { … }
void ClearTabDiscardExceptions(PrefService* pref_service,
base::Time delete_begin,
base::Time delete_end) { … }
}