| DeviceKit Reference Manual | ||||
|---|---|---|---|---|
| Top | Description | Implemented Interfaces | Properties | Signals | ||||
org.freedesktop.DeviceKitorg.freedesktop.DeviceKit — DeviceKit interface |
InhibitShutdown (out 's' cookie) UninhibitShutdown (in 's' cookie) EnumerateBySubsystem (in 'as' subsystems, out 'a(sssasa{ss})' result) EnumerateByNativePath (in 'as' native_paths, out 'a(sssasa{ss})' result)
DeviceEvent ('s' action, 's' subsystem, 's' native_path, 's' device_file, 'as' device_file_symlinks, 'a{ss}' properties)
Objects implementing org.freedesktop.DeviceKit also implements org.freedesktop.DBus.Introspectable, org.freedesktop.DBus.Properties
The DeviceKit service is available via the system message
bus. To access the service, use
the org.freedesktop.DeviceKit interface on
the /org/freedesktop/DeviceKit object on
the D-Bus system bus service with the well-known
name org.freedesktop.DeviceKit.
$ dbus-send --system \
--print-reply \
--dest=org.freedesktop.DeviceKit \
/org/freedesktop/DeviceKit \
org.freedesktop.DeviceKit.EnumerateBySubsystem \
array:string:mmc
method return sender=:1.175 -> dest=:1.219 reply_serial=2
array [
struct {
string "mmc"
string "/sys/devices/pci0000:00/0000:00:1e.0/0000:05:00.2/mmc_host/mmc0/mmc0:e624"
string ""
array [
]
array [
dict entry(
string "UDEV_LOG"
string "3"
)
dict entry(
string "SUBSYSTEM"
string "mmc"
)
dict entry(
string "DEVPATH"
string "/devices/pci0000:00/0000:00:1e.0/0000:05:00.2/mmc_host/mmc0/mmc0:e624"
)
dict entry(
string "MMC_NAME"
string "SD04G"
)
dict entry(
string "DRIVER"
string "mmcblk"
)
dict entry(
string "MMC_TYPE"
string "SD"
)
]
}
]
Keep the daemon from exiting on inactivity; this is useful for mechanisms that wants the daemon around for listening on signals.
|
The cookie that is used to stop inhibiting the daemon. |
Allow the daemon to exit when it's inactive. The cookie
parameter is the return value from InhibitShutdown().
|
The cookie. |
Enumerate devices on the system by subsystem. If the
subsystems parameter is empty devices from all subsystems
will be returned. See the DeviceEvent()
signal for a description of the return value.
|
List of subsystems to get devices from. If an empty array is passed devices from all subsystems is returned. |
|
The result as an array of structures containing the subsystem, native_path, device_file, device_file_symlinks and properties. |
Enumerate devices on the system given a list of native
paths. See the DeviceEvent() signal
for a description of the return value.
|
List of native paths. |
|
The result as an array of structures containing the subsystem, native_path, device_file, device_file_symlinks and properties. |
DeviceEvent ('s' action,
's' subsystem,
's' native_path,
's' device_file,
'as' device_file_symlinks,
'a{ss}' properties)
This signal is emitted when an event occurs on a device such as change, add, remove.
|
The OS specific event. |
|
The subsystem the device belongs to. |
|
The OS specific native path of the device. |
|
The UNIX special device file for the device. |
|
A list of symlinks pointing to the UNIX special device file. |
|
A set of key/value pairs with OS specific properties for the device. |