| 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 CHROMEOS_NETWORK_NETWORK_HANDLER_H_ | 5 #ifndef CHROMEOS_NETWORK_NETWORK_HANDLER_H_ |
| 6 #define CHROMEOS_NETWORK_NETWORK_HANDLER_H_ | 6 #define CHROMEOS_NETWORK_NETWORK_HANDLER_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| 11 #include "base/single_thread_task_runner.h" | 11 #include "base/single_thread_task_runner.h" |
| 12 #include "chromeos/chromeos_export.h" | 12 #include "chromeos/chromeos_export.h" |
| 13 | 13 |
| 14 namespace chromeos { | 14 namespace chromeos { |
| 15 | 15 |
| 16 class AutoConnectHandler; | 16 class AutoConnectHandler; |
| 17 class ClientCertResolver; | 17 class ClientCertResolver; |
| 18 class GeolocationHandler; | 18 class GeolocationHandler; |
| 19 class ManagedNetworkConfigurationHandler; | 19 class ManagedNetworkConfigurationHandler; |
| 20 class ManagedNetworkConfigurationHandlerImpl; | 20 class ManagedNetworkConfigurationHandlerImpl; |
| 21 class NetworkActivationHandler; | 21 class NetworkActivationHandler; |
| 22 class NetworkCertMigrator; | 22 class NetworkCertMigrator; |
| 23 class NetworkConfigurationHandler; | 23 class NetworkConfigurationHandler; |
| 24 class NetworkConnectionHandler; | 24 class NetworkConnectionHandler; |
| 25 class NetworkDeviceHandler; | 25 class NetworkDeviceHandler; |
| 26 class NetworkDeviceHandlerImpl; | 26 class NetworkDeviceHandlerImpl; |
| 27 class NetworkProfileHandler; | 27 class NetworkProfileHandler; |
| 28 class NetworkStateHandler; | 28 class NetworkStateHandler; |
| 29 class NetworkSmsHandler; | 29 class NetworkSmsHandler; |
| 30 class ProhibitedTechnologiesHandler; |
| 30 | 31 |
| 31 // Class for handling initialization and access to chromeos network handlers. | 32 // Class for handling initialization and access to chromeos network handlers. |
| 32 // This class should NOT be used in unit tests. Instead, construct individual | 33 // This class should NOT be used in unit tests. Instead, construct individual |
| 33 // classes independently. | 34 // classes independently. |
| 34 class CHROMEOS_EXPORT NetworkHandler { | 35 class CHROMEOS_EXPORT NetworkHandler { |
| 35 public: | 36 public: |
| 36 // Sets the global instance. Must be called before any calls to Get(). | 37 // Sets the global instance. Must be called before any calls to Get(). |
| 37 static void Initialize(); | 38 static void Initialize(); |
| 38 | 39 |
| 39 // Destroys the global instance. | 40 // Destroys the global instance. |
| (...skipping 14 matching lines...) Expand all Loading... |
| 54 // NetworkHandler. | 55 // NetworkHandler. |
| 55 NetworkStateHandler* network_state_handler(); | 56 NetworkStateHandler* network_state_handler(); |
| 56 NetworkDeviceHandler* network_device_handler(); | 57 NetworkDeviceHandler* network_device_handler(); |
| 57 NetworkProfileHandler* network_profile_handler(); | 58 NetworkProfileHandler* network_profile_handler(); |
| 58 NetworkConfigurationHandler* network_configuration_handler(); | 59 NetworkConfigurationHandler* network_configuration_handler(); |
| 59 ManagedNetworkConfigurationHandler* managed_network_configuration_handler(); | 60 ManagedNetworkConfigurationHandler* managed_network_configuration_handler(); |
| 60 NetworkActivationHandler* network_activation_handler(); | 61 NetworkActivationHandler* network_activation_handler(); |
| 61 NetworkConnectionHandler* network_connection_handler(); | 62 NetworkConnectionHandler* network_connection_handler(); |
| 62 NetworkSmsHandler* network_sms_handler(); | 63 NetworkSmsHandler* network_sms_handler(); |
| 63 GeolocationHandler* geolocation_handler(); | 64 GeolocationHandler* geolocation_handler(); |
| 65 ProhibitedTechnologiesHandler* prohibited_technologies_handler(); |
| 64 | 66 |
| 65 private: | 67 private: |
| 66 NetworkHandler(); | 68 NetworkHandler(); |
| 67 virtual ~NetworkHandler(); | 69 virtual ~NetworkHandler(); |
| 68 | 70 |
| 69 void Init(); | 71 void Init(); |
| 70 | 72 |
| 71 // The order of these determines the (inverse) destruction order. | 73 // The order of these determines the (inverse) destruction order. |
| 72 scoped_refptr<base::SingleThreadTaskRunner> task_runner_; | 74 scoped_refptr<base::SingleThreadTaskRunner> task_runner_; |
| 73 scoped_ptr<NetworkStateHandler> network_state_handler_; | 75 scoped_ptr<NetworkStateHandler> network_state_handler_; |
| 74 scoped_ptr<NetworkDeviceHandlerImpl> network_device_handler_; | 76 scoped_ptr<NetworkDeviceHandlerImpl> network_device_handler_; |
| 75 scoped_ptr<NetworkProfileHandler> network_profile_handler_; | 77 scoped_ptr<NetworkProfileHandler> network_profile_handler_; |
| 76 scoped_ptr<NetworkConfigurationHandler> network_configuration_handler_; | 78 scoped_ptr<NetworkConfigurationHandler> network_configuration_handler_; |
| 77 scoped_ptr<ManagedNetworkConfigurationHandlerImpl> | 79 scoped_ptr<ManagedNetworkConfigurationHandlerImpl> |
| 78 managed_network_configuration_handler_; | 80 managed_network_configuration_handler_; |
| 79 scoped_ptr<NetworkCertMigrator> network_cert_migrator_; | 81 scoped_ptr<NetworkCertMigrator> network_cert_migrator_; |
| 80 scoped_ptr<ClientCertResolver> client_cert_resolver_; | 82 scoped_ptr<ClientCertResolver> client_cert_resolver_; |
| 81 scoped_ptr<NetworkActivationHandler> network_activation_handler_; | 83 scoped_ptr<NetworkActivationHandler> network_activation_handler_; |
| 82 scoped_ptr<NetworkConnectionHandler> network_connection_handler_; | 84 scoped_ptr<NetworkConnectionHandler> network_connection_handler_; |
| 83 scoped_ptr<AutoConnectHandler> auto_connect_handler_; | 85 scoped_ptr<AutoConnectHandler> auto_connect_handler_; |
| 84 scoped_ptr<NetworkSmsHandler> network_sms_handler_; | 86 scoped_ptr<NetworkSmsHandler> network_sms_handler_; |
| 85 scoped_ptr<GeolocationHandler> geolocation_handler_; | 87 scoped_ptr<GeolocationHandler> geolocation_handler_; |
| 88 scoped_ptr<ProhibitedTechnologiesHandler> prohibited_technologies_handler_; |
| 86 | 89 |
| 87 DISALLOW_COPY_AND_ASSIGN(NetworkHandler); | 90 DISALLOW_COPY_AND_ASSIGN(NetworkHandler); |
| 88 }; | 91 }; |
| 89 | 92 |
| 90 } // namespace chromeos | 93 } // namespace chromeos |
| 91 | 94 |
| 92 #endif // CHROMEOS_NETWORK_NETWORK_HANDLER_H_ | 95 #endif // CHROMEOS_NETWORK_NETWORK_HANDLER_H_ |
| OLD | NEW |