| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CHROMEOS_NETWORK_NETWORK_CONFIGURATION_HANDLER_H_ | 5 #ifndef CHROMEOS_NETWORK_NETWORK_CONFIGURATION_HANDLER_H_ |
| 6 #define CHROMEOS_NETWORK_NETWORK_CONFIGURATION_HANDLER_H_ | 6 #define CHROMEOS_NETWORK_NETWORK_CONFIGURATION_HANDLER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 28 matching lines...) Expand all Loading... |
| 39 // that is suitable for logging. None of the error message text is meant for | 39 // that is suitable for logging. None of the error message text is meant for |
| 40 // user consumption. | 40 // user consumption. |
| 41 | 41 |
| 42 class CHROMEOS_EXPORT NetworkConfigurationHandler { | 42 class CHROMEOS_EXPORT NetworkConfigurationHandler { |
| 43 public: | 43 public: |
| 44 ~NetworkConfigurationHandler(); | 44 ~NetworkConfigurationHandler(); |
| 45 | 45 |
| 46 // Sets the global instance. Must be called before any calls to Get(). | 46 // Sets the global instance. Must be called before any calls to Get(). |
| 47 static void Initialize(); | 47 static void Initialize(); |
| 48 | 48 |
| 49 // Returns if the singleton is initialized. |
| 50 static bool IsInitialized(); |
| 51 |
| 49 // Destroys the global instance. | 52 // Destroys the global instance. |
| 50 static void Shutdown(); | 53 static void Shutdown(); |
| 51 | 54 |
| 52 // Gets the global instance. Initialize() must be called first. | 55 // Gets the global instance. Initialize() must be called first. |
| 53 static NetworkConfigurationHandler* Get(); | 56 static NetworkConfigurationHandler* Get(); |
| 54 | 57 |
| 55 // Gets the properties of the network with id |service_path|. See note on | 58 // Gets the properties of the network with id |service_path|. See note on |
| 56 // |callback| and |error_callback|, in class description above. | 59 // |callback| and |error_callback|, in class description above. |
| 57 void GetProperties( | 60 void GetProperties( |
| 58 const std::string& service_path, | 61 const std::string& service_path, |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 113 private: | 116 private: |
| 114 friend class NetworkConfigurationHandlerTest; | 117 friend class NetworkConfigurationHandlerTest; |
| 115 NetworkConfigurationHandler(); | 118 NetworkConfigurationHandler(); |
| 116 | 119 |
| 117 DISALLOW_COPY_AND_ASSIGN(NetworkConfigurationHandler); | 120 DISALLOW_COPY_AND_ASSIGN(NetworkConfigurationHandler); |
| 118 }; | 121 }; |
| 119 | 122 |
| 120 } // namespace chromeos | 123 } // namespace chromeos |
| 121 | 124 |
| 122 #endif // CHROMEOS_NETWORK_NETWORK_CONFIGURATION_HANDLER_H_ | 125 #endif // CHROMEOS_NETWORK_NETWORK_CONFIGURATION_HANDLER_H_ |
| OLD | NEW |