OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef EXTENSIONS_BROWSER_API_NETWORKING_PRIVATE_NETWORKING_PRIVATE_DELEGATE_H_ | 5 #ifndef EXTENSIONS_BROWSER_API_NETWORKING_PRIVATE_NETWORKING_PRIVATE_DELEGATE_H_ |
6 #define EXTENSIONS_BROWSER_API_NETWORKING_PRIVATE_NETWORKING_PRIVATE_DELEGATE_H_ | 6 #define EXTENSIONS_BROWSER_API_NETWORKING_PRIVATE_NETWORKING_PRIVATE_DELEGATE_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
134 | 134 |
135 // Returns a list of DeviceStateProperties. | 135 // Returns a list of DeviceStateProperties. |
136 virtual std::unique_ptr<DeviceStateList> GetDeviceStateList() = 0; | 136 virtual std::unique_ptr<DeviceStateList> GetDeviceStateList() = 0; |
137 | 137 |
138 // Returns a dictionary of global policy values (may be empty). Note: the | 138 // Returns a dictionary of global policy values (may be empty). Note: the |
139 // dictionary is expected to be a superset of the networkingPrivate | 139 // dictionary is expected to be a superset of the networkingPrivate |
140 // GlobalPolicy dictionary. Any properties not in GlobalPolicy will be | 140 // GlobalPolicy dictionary. Any properties not in GlobalPolicy will be |
141 // ignored. | 141 // ignored. |
142 virtual std::unique_ptr<base::DictionaryValue> GetGlobalPolicy() = 0; | 142 virtual std::unique_ptr<base::DictionaryValue> GetGlobalPolicy() = 0; |
143 | 143 |
| 144 // Returns a dictionary of certificate lists. |
| 145 virtual std::unique_ptr<base::DictionaryValue> GetCertificateLists() = 0; |
| 146 |
144 // Returns true if the ONC network type |type| is enabled. | 147 // Returns true if the ONC network type |type| is enabled. |
145 virtual bool EnableNetworkType(const std::string& type) = 0; | 148 virtual bool EnableNetworkType(const std::string& type) = 0; |
146 | 149 |
147 // Returns true if the ONC network type |type| is disabled. | 150 // Returns true if the ONC network type |type| is disabled. |
148 virtual bool DisableNetworkType(const std::string& type) = 0; | 151 virtual bool DisableNetworkType(const std::string& type) = 0; |
149 | 152 |
150 // Returns true if a scan was requested. It may take many seconds for a scan | 153 // Returns true if a scan was requested. It may take many seconds for a scan |
151 // to complete. The scan may or may not trigger API events when complete. | 154 // to complete. The scan may or may not trigger API events when complete. |
152 virtual bool RequestScan() = 0; | 155 virtual bool RequestScan() = 0; |
153 | 156 |
154 // Optional methods for adding a NetworkingPrivateDelegateObserver for | 157 // Optional methods for adding a NetworkingPrivateDelegateObserver for |
155 // implementations that require it (non-chromeos). | 158 // implementations that require it (non-chromeos). |
156 virtual void AddObserver(NetworkingPrivateDelegateObserver* observer); | 159 virtual void AddObserver(NetworkingPrivateDelegateObserver* observer); |
157 virtual void RemoveObserver(NetworkingPrivateDelegateObserver* observer); | 160 virtual void RemoveObserver(NetworkingPrivateDelegateObserver* observer); |
158 | 161 |
159 private: | 162 private: |
160 // Interface for UI methods. May be null. | 163 // Interface for UI methods. May be null. |
161 std::unique_ptr<UIDelegate> ui_delegate_; | 164 std::unique_ptr<UIDelegate> ui_delegate_; |
162 | 165 |
163 DISALLOW_COPY_AND_ASSIGN(NetworkingPrivateDelegate); | 166 DISALLOW_COPY_AND_ASSIGN(NetworkingPrivateDelegate); |
164 }; | 167 }; |
165 | 168 |
166 } // namespace extensions | 169 } // namespace extensions |
167 | 170 |
168 #endif // EXTENSIONS_BROWSER_API_NETWORKING_PRIVATE_NETWORKING_PRIVATE_DELEGATE
_H_ | 171 #endif // EXTENSIONS_BROWSER_API_NETWORKING_PRIVATE_NETWORKING_PRIVATE_DELEGATE
_H_ |
OLD | NEW |