| 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_DBUS_FLIMFLAM_PROFILE_CLIENT_H_ | 5 #ifndef CHROMEOS_DBUS_SHILL_PROFILE_CLIENT_H_ |
| 6 #define CHROMEOS_DBUS_FLIMFLAM_PROFILE_CLIENT_H_ | 6 #define CHROMEOS_DBUS_SHILL_PROFILE_CLIENT_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| 11 #include "base/callback.h" | 11 #include "base/callback.h" |
| 12 #include "chromeos/chromeos_export.h" | 12 #include "chromeos/chromeos_export.h" |
| 13 #include "chromeos/dbus/dbus_client_implementation_type.h" | 13 #include "chromeos/dbus/dbus_client_implementation_type.h" |
| 14 #include "chromeos/dbus/flimflam_client_helper.h" | 14 #include "chromeos/dbus/shill_client_helper.h" |
| 15 | 15 |
| 16 namespace base { | 16 namespace base { |
| 17 | 17 |
| 18 class Value; | 18 class Value; |
| 19 class DictionaryValue; | 19 class DictionaryValue; |
| 20 | 20 |
| 21 } // namespace base | 21 } // namespace base |
| 22 | 22 |
| 23 namespace dbus { | 23 namespace dbus { |
| 24 | 24 |
| 25 class Bus; | 25 class Bus; |
| 26 class ObjectPath; | 26 class ObjectPath; |
| 27 | 27 |
| 28 } // namespace dbus | 28 } // namespace dbus |
| 29 | 29 |
| 30 namespace chromeos { | 30 namespace chromeos { |
| 31 | 31 |
| 32 // FlimflamProfileClient is used to communicate with the Flimflam Profile | 32 // ShillProfileClient is used to communicate with the Shill Profile |
| 33 // service. All methods should be called from the origin thread which | 33 // service. All methods should be called from the origin thread which |
| 34 // initializes the DBusThreadManager instance. | 34 // initializes the DBusThreadManager instance. |
| 35 class CHROMEOS_EXPORT FlimflamProfileClient { | 35 class CHROMEOS_EXPORT ShillProfileClient { |
| 36 public: | 36 public: |
| 37 typedef FlimflamClientHelper::PropertyChangedHandler PropertyChangedHandler; | 37 typedef ShillClientHelper::PropertyChangedHandler PropertyChangedHandler; |
| 38 typedef FlimflamClientHelper::DictionaryValueCallback DictionaryValueCallback; | 38 typedef ShillClientHelper::DictionaryValueCallback DictionaryValueCallback; |
| 39 | 39 |
| 40 virtual ~FlimflamProfileClient(); | 40 virtual ~ShillProfileClient(); |
| 41 | 41 |
| 42 // Factory function, creates a new instance which is owned by the caller. | 42 // Factory function, creates a new instance which is owned by the caller. |
| 43 // For normal usage, access the singleton via DBusThreadManager::Get(). | 43 // For normal usage, access the singleton via DBusThreadManager::Get(). |
| 44 static FlimflamProfileClient* Create(DBusClientImplementationType type, | 44 static ShillProfileClient* Create(DBusClientImplementationType type, |
| 45 dbus::Bus* bus); | 45 dbus::Bus* bus); |
| 46 | 46 |
| 47 // Sets PropertyChanged signal handler. | 47 // Sets PropertyChanged signal handler. |
| 48 virtual void SetPropertyChangedHandler( | 48 virtual void SetPropertyChangedHandler( |
| 49 const dbus::ObjectPath& profile_path, | 49 const dbus::ObjectPath& profile_path, |
| 50 const PropertyChangedHandler& handler) = 0; | 50 const PropertyChangedHandler& handler) = 0; |
| 51 | 51 |
| 52 // Resets PropertyChanged signal handler. | 52 // Resets PropertyChanged signal handler. |
| 53 virtual void ResetPropertyChangedHandler( | 53 virtual void ResetPropertyChangedHandler( |
| 54 const dbus::ObjectPath& profile_path) = 0; | 54 const dbus::ObjectPath& profile_path) = 0; |
| (...skipping 10 matching lines...) Expand all Loading... |
| 65 const DictionaryValueCallback& callback) = 0; | 65 const DictionaryValueCallback& callback) = 0; |
| 66 | 66 |
| 67 // Calls DeleteEntry method. | 67 // Calls DeleteEntry method. |
| 68 // |callback| is called after the method call succeeds. | 68 // |callback| is called after the method call succeeds. |
| 69 virtual void DeleteEntry(const dbus::ObjectPath& profile_path, | 69 virtual void DeleteEntry(const dbus::ObjectPath& profile_path, |
| 70 const std::string& entry_path, | 70 const std::string& entry_path, |
| 71 const VoidDBusMethodCallback& callback) = 0; | 71 const VoidDBusMethodCallback& callback) = 0; |
| 72 | 72 |
| 73 protected: | 73 protected: |
| 74 // Create() should be used instead. | 74 // Create() should be used instead. |
| 75 FlimflamProfileClient(); | 75 ShillProfileClient(); |
| 76 | 76 |
| 77 private: | 77 private: |
| 78 DISALLOW_COPY_AND_ASSIGN(FlimflamProfileClient); | 78 DISALLOW_COPY_AND_ASSIGN(ShillProfileClient); |
| 79 }; | 79 }; |
| 80 | 80 |
| 81 } // namespace chromeos | 81 } // namespace chromeos |
| 82 | 82 |
| 83 #endif // CHROMEOS_DBUS_FLIMFLAM_PROFILE_CLIENT_H_ | 83 #endif // CHROMEOS_DBUS_SHILL_PROFILE_CLIENT_H_ |
| OLD | NEW |