Chromium Code Reviews| Index: dbus_control_int.h |
| diff --git a/dbus_control_int.h b/dbus_control_int.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..4e35f9a5b898996117ed295a503205a44d978521 |
| --- /dev/null |
| +++ b/dbus_control_int.h |
| @@ -0,0 +1,69 @@ |
| +// Copyright (c) 2011 The Chromium OS Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef SHILL_DBUS_CONTROL_INT_H_ |
| +#define SHILL_DBUS_CONTROL_INT_ |
| + |
| +#include <string> |
| + |
| +namespace shill { |
| + |
| +// Superclass for all DBus-backed Proxy objects |
| +class DBusProxy : public ProxyInterface { |
| + public: |
| + void SetProperty(const string &key, const string &value); |
| + const string *GetProperty(const string &key); |
| + void ClearProperty(const string &key); |
| + |
| + protected: |
| + string interface_; |
| + string path_; |
| +}; |
| + |
| +class DBusControl; |
| + |
| +// Subclass of DBusProxy for Manager objects |
| +class DBusManagerProxy : protected DBusProxy, public ManagerProxyInterface { |
|
Chris Masone
2011/03/10 18:44:15
I might name these things differently to make it c
|
| + public: |
| + explicit DBusManagerProxy(Manager *manager); |
| + void UpdateRunning(); |
| + |
| + private: |
| + static const char kInterfaceName[]; |
| + static const char kPath[]; |
| + string interface_; |
| + string path_; |
| + Manager *manager_; |
| +}; |
| + |
| +// Subclass of DBusProxy for Service objects |
| +class DBusServiceProxy : protected DBusProxy, public ServiceProxyInterface { |
| + public: |
| + explicit DBusServiceProxy(Service *service); |
| + void UpdateConnected(); |
| + |
| + private: |
| + static const char kInterfaceName[]; |
| + static const char kPath[]; |
| + string interface_; |
| + string path_; |
| + Service *service_; |
| +}; |
| + |
| +// Subclass of DBusProxy for Device objects |
| +class DBusDeviceProxy : protected DBusProxy, public DeviceProxyInterface { |
| + public: |
| + explicit DBusDeviceProxy(Device *device); |
| + void UpdateEnabled(); |
| + |
| + private: |
| + static const char kInterfaceName[]; |
| + static const char kPath[]; |
| + string interface_; |
| + string path_; |
| + Device *device_; |
| +}; |
| + |
| +} // namespace shill |
| +#endif // SHILL_DBUS_CONTROL_INT_ |