proxy_config_handler.h revision ca12bfac764ba476d6cd062bf1dde12cc64c3f40
1// Copyright (c) 2013 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_CHROMEOS_NET_PROXY_CONFIG_HANDLER_H_ 6#define CHROME_BROWSER_CHROMEOS_NET_PROXY_CONFIG_HANDLER_H_ 7 8#include "base/memory/scoped_ptr.h" 9#include "chromeos/network/onc/onc_constants.h" 10 11class PrefRegistrySimple; 12class PrefService; 13class ProxyConfigDictionary; 14 15namespace user_prefs { 16class PrefRegistrySyncable; 17} 18 19namespace chromeos { 20 21class NetworkState; 22 23namespace proxy_config { 24 25// Get the proxy configuration including per-network policies for network 26// |network|. If |profile_prefs| is NULL, then only shared settings (and device 27// policy) are respected. This is e.g. the case for the signin screen and the 28// system request context. 29scoped_ptr<ProxyConfigDictionary> GetProxyConfigForNetwork( 30 const PrefService* profile_prefs, 31 const PrefService* local_state_prefs, 32 const NetworkState& network, 33 onc::ONCSource* onc_source); 34 35void SetProxyConfigForNetwork(const ProxyConfigDictionary& proxy_config, 36 const NetworkState& network); 37 38void RegisterPrefs(PrefRegistrySimple* registry); 39 40void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry); 41 42} // namespace proxy_config 43 44} // namespace chromeos 45 46#endif // CHROME_BROWSER_CHROMEOS_NET_PROXY_CONFIG_HANDLER_H_ 47