1SD_BUS_SLOT_GET_BUS(3) sd_bus_slot_get_bus SD_BUS_SLOT_GET_BUS(3)
2
3
4
6 sd_bus_slot_get_bus, sd_bus_slot_get_current_handler,
7 sd_bus_slot_get_current_message, sd_bus_slot_get_current_userdata -
8 Query information attached to a bus slot object
9
11 #include <systemd/sd-bus.h>
12
13 typedef int (*sd_bus_message_handler_t)(sd_bus_message *m,
14 void *userdata,
15 sd_bus_error *ret_error);
16
17 sd_bus *sd_bus_slot_get_bus(sd_bus_slot *slot);
18
19 sd_bus_message_handler_t
20 sd_bus_slot_get_current_handler(sd_bus_slot *slot);
21
22 sd_bus_message *sd_bus_slot_get_current_message(sd_bus_slot *slot);
23
24 void *sd_bus_slot_get_current_userdata(sd_bus_slot *slot);
25
27 sd_bus_slot_get_bus() returns the bus object that message slot is
28 attached to.
29
30 sd_bus_slot_get_current_handler(), sd_bus_slot_get_current_message()
31 and sd_bus_slot_get_current_userdata() return the current handler,
32 message and userdata respectively of the bus slot is attached to if
33 we're currently executing the callback associated with slot.
34
36 sd_bus_slot_get_bus() always returns the bus object.
37
38 On success, sd_bus_slot_get_current_handler(),
39 sd_bus_slot_get_current_message() and
40 sd_bus_slot_get_current_userdata() return the requested object. On
41 failure, they return NULL.
42
44 These APIs are implemented as a shared library, which can be compiled
45 and linked to with the libsystemd pkg-config(1) file.
46
48 systemd(1), sd-bus(3),
49
50
51
52systemd 249 SD_BUS_SLOT_GET_BUS(3)