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 DBUS_OBJECT_PROXY_H_ | 5 #ifndef DBUS_OBJECT_PROXY_H_ |
6 #define DBUS_OBJECT_PROXY_H_ | 6 #define DBUS_OBJECT_PROXY_H_ |
7 | 7 |
8 #include <dbus/dbus.h> | 8 #include <dbus/dbus.h> |
9 | 9 |
10 #include <map> | 10 #include <map> |
(...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
159 // Runs the callback as soon as the service becomes available. | 159 // Runs the callback as soon as the service becomes available. |
160 virtual void WaitForServiceToBeAvailable( | 160 virtual void WaitForServiceToBeAvailable( |
161 WaitForServiceToBeAvailableCallback callback); | 161 WaitForServiceToBeAvailableCallback callback); |
162 | 162 |
163 // Detaches from the remote object. The Bus object will take care of | 163 // Detaches from the remote object. The Bus object will take care of |
164 // detaching so you don't have to do this manually. | 164 // detaching so you don't have to do this manually. |
165 // | 165 // |
166 // BLOCKING CALL. | 166 // BLOCKING CALL. |
167 virtual void Detach(); | 167 virtual void Detach(); |
168 | 168 |
| 169 const ObjectPath& object_path() const { return object_path_; } |
| 170 |
169 // Returns an empty callback that does nothing. Can be used for | 171 // Returns an empty callback that does nothing. Can be used for |
170 // CallMethod(). | 172 // CallMethod(). |
171 static ResponseCallback EmptyResponseCallback(); | 173 static ResponseCallback EmptyResponseCallback(); |
172 | 174 |
173 protected: | 175 protected: |
174 // This is protected, so we can define sub classes. | 176 // This is protected, so we can define sub classes. |
175 virtual ~ObjectProxy(); | 177 virtual ~ObjectProxy(); |
176 | 178 |
177 private: | 179 private: |
178 friend class base::RefCountedThreadSafe<ObjectProxy>; | 180 friend class base::RefCountedThreadSafe<ObjectProxy>; |
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
304 | 306 |
305 // Known name owner of the well-known bus name represnted by |service_name_|. | 307 // Known name owner of the well-known bus name represnted by |service_name_|. |
306 std::string service_name_owner_; | 308 std::string service_name_owner_; |
307 | 309 |
308 DISALLOW_COPY_AND_ASSIGN(ObjectProxy); | 310 DISALLOW_COPY_AND_ASSIGN(ObjectProxy); |
309 }; | 311 }; |
310 | 312 |
311 } // namespace dbus | 313 } // namespace dbus |
312 | 314 |
313 #endif // DBUS_OBJECT_PROXY_H_ | 315 #endif // DBUS_OBJECT_PROXY_H_ |
OLD | NEW |