register_object_with_closures


Description:

[ Version ( deprecated = true , deprecated_since = "2.84" , since = "2.46" ) ]
public uint register_object_with_closures (string object_path, DBusInterfaceInfo interface_info, Closure? method_call_closure, Closure? get_property_closure, Closure? set_property_closure) throws Error

Warning: register_object_with_closures is deprecated since 2.84.

Version of register_object using closures instead of a DBusInterfaceVTable for easier binding in other languages.

Note:

Deprecated in favour of [method@Gio.DBusConnection.register_object_with_closures2], which has more binding-friendly reference counting semantics.

Note that the reference counting semantics of the function wrapped by method_call_closure are the same as those of [ callback@Gio.DBusInterfaceMethodCallFunc]: ownership of a reference to the [class@Gio.DBusMethodInvocation] is transferred to the function.

Parameters:

this

A DBusConnection.

object_path

The object path to register at.

interface_info

Introspection data for the interface.

method_call_closure

Closure for handling incoming method calls.

get_property_closure

Closure for getting a property.

set_property_closure

Closure for setting a property.

Returns:

0 if throws is set, otherwise a registration ID (never 0) that can be used with unregister_object .