Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(972)

Unified Diff: chrome/browser/prefs/proxy_config_dictionary.h

Issue 1221033002: Add proxy_config component (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update copyrights Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/prefs/proxy_config_dictionary.h
diff --git a/chrome/browser/prefs/proxy_config_dictionary.h b/chrome/browser/prefs/proxy_config_dictionary.h
deleted file mode 100644
index 1593768fbd6b713c976dc21ab7310615b94398e2..0000000000000000000000000000000000000000
--- a/chrome/browser/prefs/proxy_config_dictionary.h
+++ /dev/null
@@ -1,63 +0,0 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef CHROME_BROWSER_PREFS_PROXY_CONFIG_DICTIONARY_H_
-#define CHROME_BROWSER_PREFS_PROXY_CONFIG_DICTIONARY_H_
-
-#include <string>
-
-#include "base/basictypes.h"
-#include "base/memory/scoped_ptr.h"
-#include "chrome/browser/prefs/proxy_prefs.h"
-
-namespace base {
-class DictionaryValue;
-}
-
-// Factory and wrapper for proxy config dictionaries that are stored
-// in the user preferences. The dictionary has the following structure:
-// {
-// mode: string,
-// server: string,
-// pac_url: string,
-// bypass_list: string
-// }
-// See proxy_config_dictionary.cc for the structure of the respective strings.
-class ProxyConfigDictionary {
- public:
- // Creates a deep copy of |dict| and leaves ownership to caller.
- explicit ProxyConfigDictionary(const base::DictionaryValue* dict);
- ~ProxyConfigDictionary();
-
- bool GetMode(ProxyPrefs::ProxyMode* out) const;
- bool GetPacUrl(std::string* out) const;
- bool GetPacMandatory(bool* out) const;
- bool GetProxyServer(std::string* out) const;
- bool GetBypassList(std::string* out) const;
- bool HasBypassList() const;
-
- const base::DictionaryValue& GetDictionary() const;
-
- static base::DictionaryValue* CreateDirect();
- static base::DictionaryValue* CreateAutoDetect();
- static base::DictionaryValue* CreatePacScript(const std::string& pac_url,
- bool pac_mandatory);
- static base::DictionaryValue* CreateFixedServers(
- const std::string& proxy_server,
- const std::string& bypass_list);
- static base::DictionaryValue* CreateSystem();
- private:
- static base::DictionaryValue* CreateDictionary(
- ProxyPrefs::ProxyMode mode,
- const std::string& pac_url,
- bool pac_mandatory,
- const std::string& proxy_server,
- const std::string& bypass_list);
-
- scoped_ptr<base::DictionaryValue> dict_;
-
- DISALLOW_COPY_AND_ASSIGN(ProxyConfigDictionary);
-};
-
-#endif // CHROME_BROWSER_PREFS_PROXY_CONFIG_DICTIONARY_H_
« no previous file with comments | « chrome/browser/prefs/command_line_pref_store_unittest.cc ('k') | chrome/browser/prefs/proxy_config_dictionary.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698