Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(105)

Side by Side Diff: chromeos/network/network_configuration_handler.h

Issue 14566009: Add NetworkConnectionHandler class (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Revert Associating Stub change for test Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
73 // unable to be cleared, the |error_callback| will only be run once with 73 // unable to be cleared, the |error_callback| will only be run once with
74 // accumulated information about all of the errors as a list attached to the 74 // accumulated information about all of the errors as a list attached to the
75 // "errors" key of the error data, and the |callback| will not be run, even 75 // "errors" key of the error data, and the |callback| will not be run, even
76 // though some of the properties may have been cleared. If there are no 76 // though some of the properties may have been cleared. If there are no
77 // errors, |callback| will be run. 77 // errors, |callback| will be run.
78 void ClearProperties(const std::string& service_path, 78 void ClearProperties(const std::string& service_path,
79 const std::vector<std::string>& property_paths, 79 const std::vector<std::string>& property_paths,
80 const base::Closure& callback, 80 const base::Closure& callback,
81 const network_handler::ErrorCallback& error_callback); 81 const network_handler::ErrorCallback& error_callback);
82 82
83 // Initiates a connection with network that has id |service_path|. See note on
84 // |callback| and |error_callback|, in class description above.
85 void Connect(const std::string& service_path,
86 const base::Closure& callback,
87 const network_handler::ErrorCallback& error_callback) const;
88
89 // Initiates a disconnect with the network at |service_path|. See note on
90 // |callback| and |error_callback|, in class description above.
91 void Disconnect(const std::string& service_path,
92 const base::Closure& callback,
93 const network_handler::ErrorCallback& error_callback) const;
94
95
96 // Creates a network with the given properties in the active Shill profile, 83 // Creates a network with the given properties in the active Shill profile,
97 // and returns the new service_path to |callback| if successful. See note on 84 // and returns the new service_path to |callback| if successful. See note on
98 // |callback| and |error_callback|, in class description above. 85 // |callback| and |error_callback|, in class description above.
99 void CreateConfiguration( 86 void CreateConfiguration(
100 const base::DictionaryValue& properties, 87 const base::DictionaryValue& properties,
101 const network_handler::StringResultCallback& callback, 88 const network_handler::StringResultCallback& callback,
102 const network_handler::ErrorCallback& error_callback) const; 89 const network_handler::ErrorCallback& error_callback) const;
103 90
104 // Removes the network |service_path| from the remembered network list in the 91 // Removes the network |service_path| from the remembered network list in the
105 // active Shill profile. The network may still show up in the visible networks 92 // active Shill profile. The network may still show up in the visible networks
106 // after this, but no profile configuration will remain. See note on 93 // after this, but no profile configuration will remain. See note on
107 // |callback| and |error_callback|, in class description above. 94 // |callback| and |error_callback|, in class description above.
108 void RemoveConfiguration( 95 void RemoveConfiguration(
109 const std::string& service_path, 96 const std::string& service_path,
110 const base::Closure& callback, 97 const base::Closure& callback,
111 const network_handler::ErrorCallback& error_callback) const; 98 const network_handler::ErrorCallback& error_callback) const;
112 99
113 private: 100 private:
114 friend class NetworkConfigurationHandlerTest; 101 friend class NetworkConfigurationHandlerTest;
115 NetworkConfigurationHandler(); 102 NetworkConfigurationHandler();
116 103
117 DISALLOW_COPY_AND_ASSIGN(NetworkConfigurationHandler); 104 DISALLOW_COPY_AND_ASSIGN(NetworkConfigurationHandler);
118 }; 105 };
119 106
120 } // namespace chromeos 107 } // namespace chromeos
121 108
122 #endif // CHROMEOS_NETWORK_NETWORK_CONFIGURATION_HANDLER_H_ 109 #endif // CHROMEOS_NETWORK_NETWORK_CONFIGURATION_HANDLER_H_
OLDNEW
« no previous file with comments | « chromeos/network/managed_network_configuration_handler.cc ('k') | chromeos/network/network_configuration_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698