glibmm 2.80.0
|
This represents a virtual table for handling properties and method calls for a D-Bus interface. More...
#include <giomm/dbusinterfacevtable.h>
Public Types | |
using | SlotInterfaceMethodCall = sigc::slot< void(const Glib::RefPtr< Connection > &, const Glib::ustring &, const Glib::ustring &, const Glib::ustring &, const Glib::ustring &, const Glib::VariantContainerBase &, const Glib::RefPtr< MethodInvocation > &) > |
The type for a slot which handles a method call for a D-Bus interface. | |
using | SlotInterfaceGetProperty = sigc::slot< void(Glib::VariantBase &, const Glib::RefPtr< Connection > &, const Glib::ustring &, const Glib::ustring &, const Glib::ustring &, const Glib::ustring &) > |
The type for a slot which handles getting a property for a D-Bus interface. | |
using | SlotInterfaceSetProperty = sigc::slot< bool(const Glib::RefPtr< Connection > &, const Glib::ustring &, const Glib::ustring &, const Glib::ustring &, const Glib::ustring &, const Glib::VariantBase &) > |
The type for a slot which handles setting a property for a D-Bus interface. | |
Public Member Functions | |
InterfaceVTable (const SlotInterfaceMethodCall &slot_method_call, const SlotInterfaceGetProperty &slot_get_property={}, const SlotInterfaceSetProperty &slot_set_property={}) | |
Constructs a new InterfaceVTable using the specified slots. | |
InterfaceVTable (const InterfaceVTable &other)=delete | |
InterfaceVTable & | operator= (const InterfaceVTable &other)=delete |
InterfaceVTable (InterfaceVTable &&other) noexcept | |
InterfaceVTable & | operator= (InterfaceVTable &&other) noexcept |
virtual | ~InterfaceVTable () |
Destructor. | |
GDBusInterfaceVTable * | gobj () |
Provides access to the underlying C object. | |
const GDBusInterfaceVTable * | gobj () const |
Provides access to the underlying C object. | |
Protected Attributes | |
GDBusInterfaceVTable | gobject_ |
SlotInterfaceMethodCall * | slot_method_call_ |
SlotInterfaceGetProperty * | slot_get_property_ |
SlotInterfaceSetProperty * | slot_set_property_ |
This represents a virtual table for handling properties and method calls for a D-Bus interface.
If you want to handle getting/setting D-Bus properties asynchronously, simply register an object with the org.freedesktop.DBus.Properties D-Bus interface using Gio::DBus::Connection::register_object().
The only correct use of this class is to declare a global instance of it (or an instance local to the main function) and pass pointers to the instance to the methods that require such a parameter. The instance can be used for multiple registrations and the memory it uses will be freed at the end of execution. Any other use (like creating an instance local to a function and using that) may cause memory leaks or errors (if the instance is destroyed too early).
The type for a slot which handles getting a property for a D-Bus interface.
for example,
Glib::Error. |
The type for a slot which handles a method call for a D-Bus interface.
for example,
using Gio::DBus::InterfaceVTable::SlotInterfaceSetProperty = sigc::slot< bool( const Glib::RefPtr<Connection>&, const Glib::ustring&, const Glib::ustring&, const Glib::ustring&, const Glib::ustring&, const Glib::VariantBase&) > |
The type for a slot which handles setting a property for a D-Bus interface.
for example,
Glib::Error. |
|
explicit |
Constructs a new InterfaceVTable using the specified slots.
slot_method_call | The slot for handling incoming method calls. |
slot_get_property | The slot for getting a property. |
slot_set_property | The slot for setting a property. |
|
delete |
|
noexcept |
|
virtual |
Destructor.
|
inline |
Provides access to the underlying C object.
|
inline |
Provides access to the underlying C object.
|
delete |
|
noexcept |
|
protected |
|
protected |
|
protected |
|
protected |