Expand description
Iteration over backlight devices.
§Usage
The default directory for backlight devices is BACKLIGHT_PATH
,
whose value is "/sys/class/backlight"
.
The DeviceIter
iterates over…
§Examples
use std::path::Path;
for device in DeviceIter::default() {
assert_eq!(
Path::new(BACKLIGHT_PATH),
device.path().parent().unwrap());
}
Structs§
- Device
- A single backlight device that can be toggled ON and OFF.
- Device
Iter - An iterator over the devices found in a given folder.
Constants§
- BACKLIGHT_
PATH - The default directory where to look for devices.
- BL_
POWER - The default name of the file controlling the power of the device.
Functions§
- iterate_
devices - Iterate over devices in
dir
.