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 <string> | 9 #include <string> |
10 | 10 |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
78 void(const NetworkList& network_list)> NetworkListCallback; | 78 void(const NetworkList& network_list)> NetworkListCallback; |
79 | 79 |
80 typedef base::Callback< | 80 typedef base::Callback< |
81 void(const std::string& service_path)> StringResultCallback; | 81 void(const std::string& service_path)> StringResultCallback; |
82 | 82 |
83 typedef base::Callback< | 83 typedef base::Callback< |
84 void(const NetworkGuidList& network_guid_list)> NetworkGuidListCallback; | 84 void(const NetworkGuidList& network_guid_list)> NetworkGuidListCallback; |
85 | 85 |
86 virtual ~WiFiService() {} | 86 virtual ~WiFiService() {} |
87 | 87 |
| 88 // Initialize WiFiService, return |true| if successful. |
| 89 virtual bool Initialize() = 0; |
| 90 |
| 91 // UnInitialize WiFiService. |
| 92 virtual void UnInitialize() = 0; |
| 93 |
88 // Get Properties of network identified by |network_guid|. Run |callback| on | 94 // Get Properties of network identified by |network_guid|. Run |callback| on |
89 // success, |error_callback| on failure. | 95 // success, |error_callback| on failure. |
90 virtual void GetProperties(const std::string& network_guid, | 96 virtual void GetProperties(const std::string& network_guid, |
91 const NetworkPropertiesCallback& callback, | 97 const NetworkPropertiesCallback& callback, |
92 const ErrorCallback& error_callback) = 0; | 98 const ErrorCallback& error_callback) = 0; |
93 | 99 |
94 // Get State of network identified by |network_guid|. Run |callback| on | 100 // Get State of network identified by |network_guid|. Run |callback| on |
95 // success, |error_callback| on failure. Not implemented except unit tests. | 101 // success, |error_callback| on failure. Not implemented except unit tests. |
96 virtual void GetState(const std::string& network_guid, | 102 virtual void GetState(const std::string& network_guid, |
97 const NetworkPropertiesCallback& callback, | 103 const NetworkPropertiesCallback& callback, |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
148 static WiFiService* CreateServiceMock(); | 154 static WiFiService* CreateServiceMock(); |
149 | 155 |
150 protected: | 156 protected: |
151 WiFiService() {} | 157 WiFiService() {} |
152 | 158 |
153 private: | 159 private: |
154 DISALLOW_COPY_AND_ASSIGN(WiFiService); | 160 DISALLOW_COPY_AND_ASSIGN(WiFiService); |
155 }; | 161 }; |
156 } // namespace wifi | 162 } // namespace wifi |
157 #endif // CHROME_UTILITY_WIFI_WIFI_SERVICE_H_ | 163 #endif // CHROME_UTILITY_WIFI_WIFI_SERVICE_H_ |
OLD | NEW |