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 | |
171 // Returns an empty callback that does nothing. Can be used for | 169 // Returns an empty callback that does nothing. Can be used for |
172 // CallMethod(). | 170 // CallMethod(). |
173 static ResponseCallback EmptyResponseCallback(); | 171 static ResponseCallback EmptyResponseCallback(); |
174 | 172 |
175 protected: | 173 protected: |
176 // This is protected, so we can define sub classes. | 174 // This is protected, so we can define sub classes. |
177 virtual ~ObjectProxy(); | 175 virtual ~ObjectProxy(); |
178 | 176 |
179 private: | 177 private: |
180 friend class base::RefCountedThreadSafe<ObjectProxy>; | 178 friend class base::RefCountedThreadSafe<ObjectProxy>; |
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
306 | 304 |
307 // Known name owner of the well-known bus name represnted by |service_name_|. | 305 // Known name owner of the well-known bus name represnted by |service_name_|. |
308 std::string service_name_owner_; | 306 std::string service_name_owner_; |
309 | 307 |
310 DISALLOW_COPY_AND_ASSIGN(ObjectProxy); | 308 DISALLOW_COPY_AND_ASSIGN(ObjectProxy); |
311 }; | 309 }; |
312 | 310 |
313 } // namespace dbus | 311 } // namespace dbus |
314 | 312 |
315 #endif // DBUS_OBJECT_PROXY_H_ | 313 #endif // DBUS_OBJECT_PROXY_H_ |
OLD | NEW |