Top |
org.freedesktop.UPowerorg.freedesktop.UPower — UPower interface |
EnumerateDevices (out 'ao' devices) GetDisplayDevice (out 'o' device) GetCriticalAction (out 's' action)
Objects implementing org.freedesktop.UPower also implements org.freedesktop.DBus.Introspectable, org.freedesktop.DBus.Properties
'DaemonVersion' read 's' 'OnBattery' read 'b' 'LidIsClosed' read 'b' 'LidIsPresent' read 'b'
The UPower service is available via the system message
bus. To access the service, use
the org.freedesktop.UPower
interface on
the /org/freedesktop/UPower
object on
the D-Bus system bus service with the well-known
name org.freedesktop.UPower
.
1 2 3 4 5 6 7 8 9 10 11 |
$ dbus-send --print-reply \ --system \ --dest=org.freedesktop.UPower \ /org/freedesktop/UPower \ org.freedesktop.UPower.EnumerateDevices method return sender=:1.386 -> dest=:1.451 reply_serial=2 array [ object path "/org/freedesktop/UPower/devices/line_power_AC" object path "/org/freedesktop/UPower/devices/battery_BAT0" ] |
Enumerate all power objects on the system.
|
An array of object paths for devices. |
Get the object to the "display device", a composite device that represents the
status icon to show in desktop environments. You can also access the object directly
as its path is guaranteed to be /org/freedesktop/UPower/devices/DisplayDevice.
The following standard org.freedesktop.UPower.Device
properties will be defined (only IsPresent
takes a special meaning):
WarningLevel
|
An object path for the "display device. |
When the system's power supply is critical (critically low batteries or UPS), the system will take this action. Possible values are:
|
A string representing the critical action configured and available. |
Emitted when a device is added.
|
Object path of device that was added. |
Emitted when a device is removed.
|
Object path of device that was removed. |