OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CHROME_UTILITY_WIFI_WIFI_SERVICE_H_ | 5 #ifndef CHROME_UTILITY_WIFI_WIFI_SERVICE_H_ |
6 #define CHROME_UTILITY_WIFI_WIFI_SERVICE_H_ | 6 #define CHROME_UTILITY_WIFI_WIFI_SERVICE_H_ |
7 | 7 |
8 #include <list> | 8 #include <list> |
9 #include <set> | 9 #include <set> |
10 #include <string> | 10 #include <string> |
(...skipping 23 matching lines...) Expand all Loading... |
34 | 34 |
35 // Initialize WiFiService, store |task_runner| for posting worker tasks. | 35 // Initialize WiFiService, store |task_runner| for posting worker tasks. |
36 virtual void Initialize( | 36 virtual void Initialize( |
37 scoped_refptr<base::SequencedTaskRunner> task_runner) = 0; | 37 scoped_refptr<base::SequencedTaskRunner> task_runner) = 0; |
38 | 38 |
39 // UnInitialize WiFiService. | 39 // UnInitialize WiFiService. |
40 virtual void UnInitialize() = 0; | 40 virtual void UnInitialize() = 0; |
41 | 41 |
42 // Create instance of |WiFiService| for normal use. | 42 // Create instance of |WiFiService| for normal use. |
43 static WiFiService* Create(); | 43 static WiFiService* Create(); |
44 // Create instance of |WiFiService| for unit test use. | |
45 static WiFiService* CreateForTest(); | |
46 | 44 |
47 // Get Properties of network identified by |network_guid|. Populates | 45 // Get Properties of network identified by |network_guid|. Populates |
48 // |properties| on success, |error| on failure. | 46 // |properties| on success, |error| on failure. |
49 virtual void GetProperties(const std::string& network_guid, | 47 virtual void GetProperties(const std::string& network_guid, |
50 base::DictionaryValue* properties, | 48 base::DictionaryValue* properties, |
51 std::string* error) = 0; | 49 std::string* error) = 0; |
52 | 50 |
53 // Gets the merged properties of the network with id |network_guid| from the | 51 // Gets the merged properties of the network with id |network_guid| from the |
54 // sources: User settings, shared settings, user policy, device policy and | 52 // sources: User settings, shared settings, user policy, device policy and |
55 // the currently active settings. Populates |managed_properties| on success, | 53 // the currently active settings. Populates |managed_properties| on success, |
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
166 | 164 |
167 typedef std::list<NetworkProperties> NetworkList; | 165 typedef std::list<NetworkProperties> NetworkList; |
168 | 166 |
169 private: | 167 private: |
170 DISALLOW_COPY_AND_ASSIGN(WiFiService); | 168 DISALLOW_COPY_AND_ASSIGN(WiFiService); |
171 }; | 169 }; |
172 | 170 |
173 } // namespace wifi | 171 } // namespace wifi |
174 | 172 |
175 #endif // CHROME_UTILITY_WIFI_WIFI_SERVICE_H_ | 173 #endif // CHROME_UTILITY_WIFI_WIFI_SERVICE_H_ |
OLD | NEW |