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

Unified Diff: chromeos/dbus/shill_manager_client.h

Issue 10949030: This converts the Shill clients to allow propagation of shill errors (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 8 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: chromeos/dbus/shill_manager_client.h
diff --git a/chromeos/dbus/shill_manager_client.h b/chromeos/dbus/shill_manager_client.h
index cc2117498af5158838e8952d8c274a58f66b6392..352421fa9028fc9e07dd17d1202eedde0935f1ba 100644
--- a/chromeos/dbus/shill_manager_client.h
+++ b/chromeos/dbus/shill_manager_client.h
@@ -28,20 +28,21 @@ class CHROMEOS_EXPORT ShillManagerClient {
public:
typedef ShillClientHelper::PropertyChangedHandler PropertyChangedHandler;
typedef ShillClientHelper::DictionaryValueCallback DictionaryValueCallback;
+ typedef ShillClientHelper::ErrorCallback ErrorCallback;
+ typedef ShillClientHelper::PropertyChangedObserver PropertyChangedObserver;
virtual ~ShillManagerClient();
// Factory function, creates a new instance which is owned by the caller.
// For normal usage, access the singleton via DBusThreadManager::Get().
static ShillManagerClient* Create(DBusClientImplementationType type,
- dbus::Bus* bus);
+ dbus::Bus* bus);
- // Sets PropertyChanged signal handler.
- virtual void SetPropertyChangedHandler(
- const PropertyChangedHandler& handler) = 0;
+ virtual void AddPropertyChangedObserver(
hashimoto 2012/09/21 11:52:01 Please add method comments.
Greg Spencer (Chromium) 2012/09/21 22:03:47 Done.
+ PropertyChangedObserver* observer) = 0;
- // Resets PropertyChanged signal handler.
- virtual void ResetPropertyChangedHandler() = 0;
+ virtual void RemovePropertyChangedObserver(
+ PropertyChangedObserver* observer) = 0;
// Calls GetProperties method.
// |callback| is called after the method call succeeds.
@@ -59,32 +60,38 @@ class CHROMEOS_EXPORT ShillManagerClient {
// |callback| is called after the method call succeeds.
virtual void SetProperty(const std::string& name,
const base::Value& value,
- const VoidDBusMethodCallback& callback) = 0;
+ const base::Closure& callback,
+ const ErrorCallback& error_callback) = 0;
// Calls RequestScan method.
// |callback| is called after the method call succeeds.
virtual void RequestScan(const std::string& type,
- const VoidDBusMethodCallback& callback) = 0;
+ const base::Closure& callback,
+ const ErrorCallback& error_callback) = 0;
// Calls EnableTechnology method.
// |callback| is called after the method call succeeds.
virtual void EnableTechnology(const std::string& type,
- const VoidDBusMethodCallback& callback) = 0;
+ const base::Closure& callback,
+ const ErrorCallback& error_callback) = 0;
// Calls DisableTechnology method.
// |callback| is called after the method call succeeds.
virtual void DisableTechnology(const std::string& type,
- const VoidDBusMethodCallback& callback) = 0;
+ const base::Closure& callback,
+ const ErrorCallback& error_callback) = 0;
// Calls ConfigureService method.
// |callback| is called after the method call succeeds.
virtual void ConfigureService(const base::DictionaryValue& properties,
- const VoidDBusMethodCallback& callback) = 0;
+ const base::Closure& callback,
+ const ErrorCallback& error_callback) = 0;
// Calls GetService method.
// |callback| is called after the method call succeeds.
virtual void GetService(const base::DictionaryValue& properties,
- const ObjectPathDBusMethodCallback& callback) = 0;
+ const ObjectPathDBusMethodCallback& callback,
+ const ErrorCallback& error_callback) = 0;
protected:
// Create() should be used instead.

Powered by Google App Engine
This is Rietveld 408576698