1 /* 2 * This file is part of gtkD. 3 * 4 * gtkD is free software; you can redistribute it and/or modify 5 * it under the terms of the GNU Lesser General Public License 6 * as published by the Free Software Foundation; either version 3 7 * of the License, or (at your option) any later version, with 8 * some exceptions, please read the COPYING file. 9 * 10 * gtkD is distributed in the hope that it will be useful, 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 * GNU Lesser General Public License for more details. 14 * 15 * You should have received a copy of the GNU Lesser General Public License 16 * along with gtkD; if not, write to the Free Software 17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110, USA 18 */ 19 20 // generated automatically - do not change 21 // find conversion definition on APILookup.txt 22 // implement new conversion functionalities on the wrap.utils pakage 23 24 25 module gio.DBusObjectManagerClient; 26 27 private import gio.AsyncInitableIF; 28 private import gio.AsyncInitableT; 29 private import gio.Cancellable; 30 private import gio.DBusConnection; 31 private import gio.DBusObjectManagerIF; 32 private import gio.DBusObjectManagerT; 33 private import gio.DBusObjectProxy; 34 private import gio.DBusProxy; 35 private import gio.InitableIF; 36 private import gio.InitableT; 37 private import glib.ConstructionException; 38 private import glib.ErrorG; 39 private import glib.GException; 40 private import glib.Str; 41 private import glib.Variant; 42 private import gobject.ObjectG; 43 private import gobject.Signals; 44 private import gtkc.gio; 45 public import gtkc.giotypes; 46 private import std.algorithm; 47 48 49 /** 50 * #GDBusObjectManagerClient is used to create, monitor and delete object 51 * proxies for remote objects exported by a #GDBusObjectManagerServer (or any 52 * code implementing the 53 * [org.freedesktop.DBus.ObjectManager](http://dbus.freedesktop.org/doc/dbus-specification.html#standard-interfaces-objectmanager) 54 * interface). 55 * 56 * Once an instance of this type has been created, you can connect to 57 * the #GDBusObjectManager::object-added and 58 * #GDBusObjectManager::object-removed signals and inspect the 59 * #GDBusObjectProxy objects returned by 60 * g_dbus_object_manager_get_objects(). 61 * 62 * If the name for a #GDBusObjectManagerClient is not owned by anyone at 63 * object construction time, the default behavior is to request the 64 * message bus to launch an owner for the name. This behavior can be 65 * disabled using the %G_DBUS_OBJECT_MANAGER_CLIENT_FLAGS_DO_NOT_AUTO_START 66 * flag. It's also worth noting that this only works if the name of 67 * interest is activatable in the first place. E.g. in some cases it 68 * is not possible to launch an owner for the requested name. In this 69 * case, #GDBusObjectManagerClient object construction still succeeds but 70 * there will be no object proxies 71 * (e.g. g_dbus_object_manager_get_objects() returns the empty list) and 72 * the #GDBusObjectManagerClient:name-owner property is %NULL. 73 * 74 * The owner of the requested name can come and go (for example 75 * consider a system service being restarted) – #GDBusObjectManagerClient 76 * handles this case too; simply connect to the #GObject::notify 77 * signal to watch for changes on the #GDBusObjectManagerClient:name-owner 78 * property. When the name owner vanishes, the behavior is that 79 * #GDBusObjectManagerClient:name-owner is set to %NULL (this includes 80 * emission of the #GObject::notify signal) and then 81 * #GDBusObjectManager::object-removed signals are synthesized 82 * for all currently existing object proxies. Since 83 * #GDBusObjectManagerClient:name-owner is %NULL when this happens, you can 84 * use this information to disambiguate a synthesized signal from a 85 * genuine signal caused by object removal on the remote 86 * #GDBusObjectManager. Similarly, when a new name owner appears, 87 * #GDBusObjectManager::object-added signals are synthesized 88 * while #GDBusObjectManagerClient:name-owner is still %NULL. Only when all 89 * object proxies have been added, the #GDBusObjectManagerClient:name-owner 90 * is set to the new name owner (this includes emission of the 91 * #GObject::notify signal). Furthermore, you are guaranteed that 92 * #GDBusObjectManagerClient:name-owner will alternate between a name owner 93 * (e.g. `:1.42`) and %NULL even in the case where 94 * the name of interest is atomically replaced 95 * 96 * Ultimately, #GDBusObjectManagerClient is used to obtain #GDBusProxy 97 * instances. All signals (including the 98 * org.freedesktop.DBus.Properties::PropertiesChanged signal) 99 * delivered to #GDBusProxy instances are guaranteed to originate 100 * from the name owner. This guarantee along with the behavior 101 * described above, means that certain race conditions including the 102 * "half the proxy is from the old owner and the other half is from 103 * the new owner" problem cannot happen. 104 * 105 * To avoid having the application connect to signals on the returned 106 * #GDBusObjectProxy and #GDBusProxy objects, the 107 * #GDBusObject::interface-added, 108 * #GDBusObject::interface-removed, 109 * #GDBusProxy::g-properties-changed and 110 * #GDBusProxy::g-signal signals 111 * are also emitted on the #GDBusObjectManagerClient instance managing these 112 * objects. The signals emitted are 113 * #GDBusObjectManager::interface-added, 114 * #GDBusObjectManager::interface-removed, 115 * #GDBusObjectManagerClient::interface-proxy-properties-changed and 116 * #GDBusObjectManagerClient::interface-proxy-signal. 117 * 118 * Note that all callbacks and signals are emitted in the 119 * [thread-default main context][g-main-context-push-thread-default] 120 * that the #GDBusObjectManagerClient object was constructed 121 * in. Additionally, the #GDBusObjectProxy and #GDBusProxy objects 122 * originating from the #GDBusObjectManagerClient object will be created in 123 * the same context and, consequently, will deliver signals in the 124 * same main loop. 125 * 126 * Since: 2.30 127 */ 128 public class DBusObjectManagerClient : ObjectG, AsyncInitableIF, DBusObjectManagerIF, InitableIF 129 { 130 /** the main Gtk struct */ 131 protected GDBusObjectManagerClient* gDBusObjectManagerClient; 132 133 /** Get the main Gtk struct */ 134 public GDBusObjectManagerClient* getDBusObjectManagerClientStruct(bool transferOwnership = false) 135 { 136 if (transferOwnership) 137 ownedRef = false; 138 return gDBusObjectManagerClient; 139 } 140 141 /** the main Gtk struct as a void* */ 142 protected override void* getStruct() 143 { 144 return cast(void*)gDBusObjectManagerClient; 145 } 146 147 protected override void setStruct(GObject* obj) 148 { 149 gDBusObjectManagerClient = cast(GDBusObjectManagerClient*)obj; 150 super.setStruct(obj); 151 } 152 153 /** 154 * Sets our main struct and passes it to the parent class. 155 */ 156 public this (GDBusObjectManagerClient* gDBusObjectManagerClient, bool ownedRef = false) 157 { 158 this.gDBusObjectManagerClient = gDBusObjectManagerClient; 159 super(cast(GObject*)gDBusObjectManagerClient, ownedRef); 160 } 161 162 // add the AsyncInitable capabilities 163 mixin AsyncInitableT!(GDBusObjectManagerClient); 164 165 // add the DBusObjectManager capabilities 166 mixin DBusObjectManagerT!(GDBusObjectManagerClient); 167 168 // add the Initable capabilities 169 mixin InitableT!(GDBusObjectManagerClient); 170 171 /** 172 * Finishes an operation started with g_dbus_object_manager_client_new(). 173 * 174 * Params: 175 * res = A GAsyncResult obtained from the GAsyncReadyCallback passed to the DBusObjectManager constructor. 176 * forBus = If true finish an address. 177 * 178 * Throws: GException on failure. 179 * Throws: ConstructionException GTK+ fails to create the object. 180 * 181 * Since: 2.30 182 */ 183 public this (AsyncResultIF res, bool forBus = false) 184 { 185 GError* err = null; 186 GDBusObjectManager* p; 187 188 if ( forBus ) 189 { 190 p = g_dbus_object_manager_client_new_for_bus_finish((res is null) ? null : res.getAsyncResultStruct(), &err); 191 } 192 else 193 { 194 p = g_dbus_object_manager_client_new_finish((res is null) ? null : res.getAsyncResultStruct(), &err); 195 } 196 197 if (err !is null) 198 { 199 throw new GException( new ErrorG(err) ); 200 } 201 202 if(p is null) 203 { 204 throw new ConstructionException("null returned by g_dbus_object_manager_client_new_finish((res is null) ? null : res.getAsyncResultStruct(), &err)"); 205 } 206 this(cast(GDBusObjectManagerClient*) p, true); 207 } 208 209 /** 210 */ 211 212 /** */ 213 public static GType getType() 214 { 215 return g_dbus_object_manager_client_get_type(); 216 } 217 218 /** 219 * Like g_dbus_object_manager_client_new_sync() but takes a #GBusType instead 220 * of a #GDBusConnection. 221 * 222 * This is a synchronous failable constructor - the calling thread is 223 * blocked until a reply is received. See g_dbus_object_manager_client_new_for_bus() 224 * for the asynchronous version. 225 * 226 * Params: 227 * busType = A #GBusType. 228 * flags = Zero or more flags from the #GDBusObjectManagerClientFlags enumeration. 229 * name = The owner of the control object (unique or well-known name). 230 * objectPath = The object path of the control object. 231 * getProxyTypeFunc = A #GDBusProxyTypeFunc function or %NULL to always construct #GDBusProxy proxies. 232 * getProxyTypeUserData = User data to pass to @get_proxy_type_func. 233 * getProxyTypeDestroyNotify = Free function for @get_proxy_type_user_data or %NULL. 234 * cancellable = A #GCancellable or %NULL 235 * 236 * Returns: A 237 * #GDBusObjectManagerClient object or %NULL if @error is set. Free 238 * with g_object_unref(). 239 * 240 * Since: 2.30 241 * 242 * Throws: GException on failure. 243 * Throws: ConstructionException GTK+ fails to create the object. 244 */ 245 public this(GBusType busType, GDBusObjectManagerClientFlags flags, string name, string objectPath, GDBusProxyTypeFunc getProxyTypeFunc, void* getProxyTypeUserData, GDestroyNotify getProxyTypeDestroyNotify, Cancellable cancellable) 246 { 247 GError* err = null; 248 249 auto p = g_dbus_object_manager_client_new_for_bus_sync(busType, flags, Str.toStringz(name), Str.toStringz(objectPath), getProxyTypeFunc, getProxyTypeUserData, getProxyTypeDestroyNotify, (cancellable is null) ? null : cancellable.getCancellableStruct(), &err); 250 251 if (err !is null) 252 { 253 throw new GException( new ErrorG(err) ); 254 } 255 256 if(p is null) 257 { 258 throw new ConstructionException("null returned by new_for_bus_sync"); 259 } 260 261 this(cast(GDBusObjectManagerClient*) p, true); 262 } 263 264 /** 265 * Creates a new #GDBusObjectManagerClient object. 266 * 267 * This is a synchronous failable constructor - the calling thread is 268 * blocked until a reply is received. See g_dbus_object_manager_client_new() 269 * for the asynchronous version. 270 * 271 * Params: 272 * connection = A #GDBusConnection. 273 * flags = Zero or more flags from the #GDBusObjectManagerClientFlags enumeration. 274 * name = The owner of the control object (unique or well-known name), or %NULL when not using a message bus connection. 275 * objectPath = The object path of the control object. 276 * getProxyTypeFunc = A #GDBusProxyTypeFunc function or %NULL to always construct #GDBusProxy proxies. 277 * getProxyTypeUserData = User data to pass to @get_proxy_type_func. 278 * getProxyTypeDestroyNotify = Free function for @get_proxy_type_user_data or %NULL. 279 * cancellable = A #GCancellable or %NULL 280 * 281 * Returns: A 282 * #GDBusObjectManagerClient object or %NULL if @error is set. Free 283 * with g_object_unref(). 284 * 285 * Since: 2.30 286 * 287 * Throws: GException on failure. 288 * Throws: ConstructionException GTK+ fails to create the object. 289 */ 290 public this(DBusConnection connection, GDBusObjectManagerClientFlags flags, string name, string objectPath, GDBusProxyTypeFunc getProxyTypeFunc, void* getProxyTypeUserData, GDestroyNotify getProxyTypeDestroyNotify, Cancellable cancellable) 291 { 292 GError* err = null; 293 294 auto p = g_dbus_object_manager_client_new_sync((connection is null) ? null : connection.getDBusConnectionStruct(), flags, Str.toStringz(name), Str.toStringz(objectPath), getProxyTypeFunc, getProxyTypeUserData, getProxyTypeDestroyNotify, (cancellable is null) ? null : cancellable.getCancellableStruct(), &err); 295 296 if (err !is null) 297 { 298 throw new GException( new ErrorG(err) ); 299 } 300 301 if(p is null) 302 { 303 throw new ConstructionException("null returned by new_sync"); 304 } 305 306 this(cast(GDBusObjectManagerClient*) p, true); 307 } 308 309 /** 310 * Asynchronously creates a new #GDBusObjectManagerClient object. 311 * 312 * This is an asynchronous failable constructor. When the result is 313 * ready, @callback will be invoked in the 314 * [thread-default main context][g-main-context-push-thread-default] 315 * of the thread you are calling this method from. You can 316 * then call g_dbus_object_manager_client_new_finish() to get the result. See 317 * g_dbus_object_manager_client_new_sync() for the synchronous version. 318 * 319 * Params: 320 * connection = A #GDBusConnection. 321 * flags = Zero or more flags from the #GDBusObjectManagerClientFlags enumeration. 322 * name = The owner of the control object (unique or well-known name). 323 * objectPath = The object path of the control object. 324 * getProxyTypeFunc = A #GDBusProxyTypeFunc function or %NULL to always construct #GDBusProxy proxies. 325 * getProxyTypeUserData = User data to pass to @get_proxy_type_func. 326 * getProxyTypeDestroyNotify = Free function for @get_proxy_type_user_data or %NULL. 327 * cancellable = A #GCancellable or %NULL 328 * callback = A #GAsyncReadyCallback to call when the request is satisfied. 329 * userData = The data to pass to @callback. 330 * 331 * Since: 2.30 332 */ 333 public static void newObjectManagerClient(DBusConnection connection, GDBusObjectManagerClientFlags flags, string name, string objectPath, GDBusProxyTypeFunc getProxyTypeFunc, void* getProxyTypeUserData, GDestroyNotify getProxyTypeDestroyNotify, Cancellable cancellable, GAsyncReadyCallback callback, void* userData) 334 { 335 g_dbus_object_manager_client_new((connection is null) ? null : connection.getDBusConnectionStruct(), flags, Str.toStringz(name), Str.toStringz(objectPath), getProxyTypeFunc, getProxyTypeUserData, getProxyTypeDestroyNotify, (cancellable is null) ? null : cancellable.getCancellableStruct(), callback, userData); 336 } 337 338 /** 339 * Like g_dbus_object_manager_client_new() but takes a #GBusType instead of a 340 * #GDBusConnection. 341 * 342 * This is an asynchronous failable constructor. When the result is 343 * ready, @callback will be invoked in the 344 * [thread-default main loop][g-main-context-push-thread-default] 345 * of the thread you are calling this method from. You can 346 * then call g_dbus_object_manager_client_new_for_bus_finish() to get the result. See 347 * g_dbus_object_manager_client_new_for_bus_sync() for the synchronous version. 348 * 349 * Params: 350 * busType = A #GBusType. 351 * flags = Zero or more flags from the #GDBusObjectManagerClientFlags enumeration. 352 * name = The owner of the control object (unique or well-known name). 353 * objectPath = The object path of the control object. 354 * getProxyTypeFunc = A #GDBusProxyTypeFunc function or %NULL to always construct #GDBusProxy proxies. 355 * getProxyTypeUserData = User data to pass to @get_proxy_type_func. 356 * getProxyTypeDestroyNotify = Free function for @get_proxy_type_user_data or %NULL. 357 * cancellable = A #GCancellable or %NULL 358 * callback = A #GAsyncReadyCallback to call when the request is satisfied. 359 * userData = The data to pass to @callback. 360 * 361 * Since: 2.30 362 */ 363 public static void newForBus(GBusType busType, GDBusObjectManagerClientFlags flags, string name, string objectPath, GDBusProxyTypeFunc getProxyTypeFunc, void* getProxyTypeUserData, GDestroyNotify getProxyTypeDestroyNotify, Cancellable cancellable, GAsyncReadyCallback callback, void* userData) 364 { 365 g_dbus_object_manager_client_new_for_bus(busType, flags, Str.toStringz(name), Str.toStringz(objectPath), getProxyTypeFunc, getProxyTypeUserData, getProxyTypeDestroyNotify, (cancellable is null) ? null : cancellable.getCancellableStruct(), callback, userData); 366 } 367 368 /** 369 * Gets the #GDBusConnection used by @manager. 370 * 371 * Returns: A #GDBusConnection object. Do not free, 372 * the object belongs to @manager. 373 * 374 * Since: 2.30 375 */ 376 public DBusConnection getConnection() 377 { 378 auto p = g_dbus_object_manager_client_get_connection(gDBusObjectManagerClient); 379 380 if(p is null) 381 { 382 return null; 383 } 384 385 return ObjectG.getDObject!(DBusConnection)(cast(GDBusConnection*) p); 386 } 387 388 /** 389 * Gets the flags that @manager was constructed with. 390 * 391 * Returns: Zero of more flags from the #GDBusObjectManagerClientFlags 392 * enumeration. 393 * 394 * Since: 2.30 395 */ 396 public GDBusObjectManagerClientFlags getFlags() 397 { 398 return g_dbus_object_manager_client_get_flags(gDBusObjectManagerClient); 399 } 400 401 /** 402 * Gets the name that @manager is for, or %NULL if not a message bus 403 * connection. 404 * 405 * Returns: A unique or well-known name. Do not free, the string 406 * belongs to @manager. 407 * 408 * Since: 2.30 409 */ 410 public string getName() 411 { 412 return Str.toString(g_dbus_object_manager_client_get_name(gDBusObjectManagerClient)); 413 } 414 415 /** 416 * The unique name that owns the name that @manager is for or %NULL if 417 * no-one currently owns that name. You can connect to the 418 * #GObject::notify signal to track changes to the 419 * #GDBusObjectManagerClient:name-owner property. 420 * 421 * Returns: The name owner or %NULL if no name owner 422 * exists. Free with g_free(). 423 * 424 * Since: 2.30 425 */ 426 public string getNameOwner() 427 { 428 auto retStr = g_dbus_object_manager_client_get_name_owner(gDBusObjectManagerClient); 429 430 scope(exit) Str.freeString(retStr); 431 return Str.toString(retStr); 432 } 433 434 protected class OnInterfaceProxyPropertiesChangedDelegateWrapper 435 { 436 void delegate(DBusObjectProxy, DBusProxy, Variant, string[], DBusObjectManagerClient) dlg; 437 gulong handlerId; 438 439 this(void delegate(DBusObjectProxy, DBusProxy, Variant, string[], DBusObjectManagerClient) dlg) 440 { 441 this.dlg = dlg; 442 onInterfaceProxyPropertiesChangedListeners ~= this; 443 } 444 445 void remove(OnInterfaceProxyPropertiesChangedDelegateWrapper source) 446 { 447 foreach(index, wrapper; onInterfaceProxyPropertiesChangedListeners) 448 { 449 if (wrapper.handlerId == source.handlerId) 450 { 451 onInterfaceProxyPropertiesChangedListeners[index] = null; 452 onInterfaceProxyPropertiesChangedListeners = std.algorithm.remove(onInterfaceProxyPropertiesChangedListeners, index); 453 break; 454 } 455 } 456 } 457 } 458 OnInterfaceProxyPropertiesChangedDelegateWrapper[] onInterfaceProxyPropertiesChangedListeners; 459 460 /** 461 * Emitted when one or more D-Bus properties on proxy changes. The 462 * local cache has already been updated when this signal fires. Note 463 * that both @changed_properties and @invalidated_properties are 464 * guaranteed to never be %NULL (either may be empty though). 465 * 466 * This signal exists purely as a convenience to avoid having to 467 * connect signals to all interface proxies managed by @manager. 468 * 469 * This signal is emitted in the 470 * [thread-default main context][g-main-context-push-thread-default] 471 * that @manager was constructed in. 472 * 473 * Params: 474 * objectProxy = The #GDBusObjectProxy on which an interface has properties that are changing. 475 * interfaceProxy = The #GDBusProxy that has properties that are changing. 476 * changedProperties = A #GVariant containing the properties that changed. 477 * invalidatedProperties = A %NULL terminated array of properties that was invalidated. 478 * 479 * Since: 2.30 480 */ 481 gulong addOnInterfaceProxyPropertiesChanged(void delegate(DBusObjectProxy, DBusProxy, Variant, string[], DBusObjectManagerClient) dlg, ConnectFlags connectFlags=cast(ConnectFlags)0) 482 { 483 auto wrapper = new OnInterfaceProxyPropertiesChangedDelegateWrapper(dlg); 484 wrapper.handlerId = Signals.connectData( 485 this, 486 "interface-proxy-properties-changed", 487 cast(GCallback)&callBackInterfaceProxyPropertiesChanged, 488 cast(void*)wrapper, 489 cast(GClosureNotify)&callBackInterfaceProxyPropertiesChangedDestroy, 490 connectFlags); 491 return wrapper.handlerId; 492 } 493 494 extern(C) static void callBackInterfaceProxyPropertiesChanged(GDBusObjectManagerClient* dbusobjectmanagerclientStruct, GDBusObjectProxy* objectProxy, GDBusProxy* interfaceProxy, GVariant* changedProperties, char** invalidatedProperties, OnInterfaceProxyPropertiesChangedDelegateWrapper wrapper) 495 { 496 wrapper.dlg(ObjectG.getDObject!(DBusObjectProxy)(objectProxy), ObjectG.getDObject!(DBusProxy)(interfaceProxy), new Variant(changedProperties), Str.toStringArray(invalidatedProperties), wrapper.outer); 497 } 498 499 extern(C) static void callBackInterfaceProxyPropertiesChangedDestroy(OnInterfaceProxyPropertiesChangedDelegateWrapper wrapper, GClosure* closure) 500 { 501 wrapper.remove(wrapper); 502 } 503 504 protected class OnInterfaceProxySignalDelegateWrapper 505 { 506 void delegate(DBusObjectProxy, DBusProxy, string, string, Variant, DBusObjectManagerClient) dlg; 507 gulong handlerId; 508 509 this(void delegate(DBusObjectProxy, DBusProxy, string, string, Variant, DBusObjectManagerClient) dlg) 510 { 511 this.dlg = dlg; 512 onInterfaceProxySignalListeners ~= this; 513 } 514 515 void remove(OnInterfaceProxySignalDelegateWrapper source) 516 { 517 foreach(index, wrapper; onInterfaceProxySignalListeners) 518 { 519 if (wrapper.handlerId == source.handlerId) 520 { 521 onInterfaceProxySignalListeners[index] = null; 522 onInterfaceProxySignalListeners = std.algorithm.remove(onInterfaceProxySignalListeners, index); 523 break; 524 } 525 } 526 } 527 } 528 OnInterfaceProxySignalDelegateWrapper[] onInterfaceProxySignalListeners; 529 530 /** 531 * Emitted when a D-Bus signal is received on @interface_proxy. 532 * 533 * This signal exists purely as a convenience to avoid having to 534 * connect signals to all interface proxies managed by @manager. 535 * 536 * This signal is emitted in the 537 * [thread-default main context][g-main-context-push-thread-default] 538 * that @manager was constructed in. 539 * 540 * Params: 541 * objectProxy = The #GDBusObjectProxy on which an interface is emitting a D-Bus signal. 542 * interfaceProxy = The #GDBusProxy that is emitting a D-Bus signal. 543 * senderName = The sender of the signal or NULL if the connection is not a bus connection. 544 * signalName = The signal name. 545 * parameters = A #GVariant tuple with parameters for the signal. 546 * 547 * Since: 2.30 548 */ 549 gulong addOnInterfaceProxySignal(void delegate(DBusObjectProxy, DBusProxy, string, string, Variant, DBusObjectManagerClient) dlg, ConnectFlags connectFlags=cast(ConnectFlags)0) 550 { 551 auto wrapper = new OnInterfaceProxySignalDelegateWrapper(dlg); 552 wrapper.handlerId = Signals.connectData( 553 this, 554 "interface-proxy-signal", 555 cast(GCallback)&callBackInterfaceProxySignal, 556 cast(void*)wrapper, 557 cast(GClosureNotify)&callBackInterfaceProxySignalDestroy, 558 connectFlags); 559 return wrapper.handlerId; 560 } 561 562 extern(C) static void callBackInterfaceProxySignal(GDBusObjectManagerClient* dbusobjectmanagerclientStruct, GDBusObjectProxy* objectProxy, GDBusProxy* interfaceProxy, char* senderName, char* signalName, GVariant* parameters, OnInterfaceProxySignalDelegateWrapper wrapper) 563 { 564 wrapper.dlg(ObjectG.getDObject!(DBusObjectProxy)(objectProxy), ObjectG.getDObject!(DBusProxy)(interfaceProxy), Str.toString(senderName), Str.toString(signalName), new Variant(parameters), wrapper.outer); 565 } 566 567 extern(C) static void callBackInterfaceProxySignalDestroy(OnInterfaceProxySignalDelegateWrapper wrapper, GClosure* closure) 568 { 569 wrapper.remove(wrapper); 570 } 571 }