pub struct Backlight { /* private fields */ }
Expand description
Fetch and modify brightness values of backlight controls.
Implementations§
Trait Implementations§
Source§impl Brightness for Backlight
impl Brightness for Backlight
Source§impl SysClass for Backlight
impl SysClass for Backlight
Source§fn class() -> &'static str
fn class() -> &'static str
Return the class of the sys object, the name of a folder in `/sys/${base}``
Source§unsafe fn from_path_unchecked(path: PathBuf) -> Self
unsafe fn from_path_unchecked(path: PathBuf) -> Self
Create a sys object from an absolute path without checking path for validity
Source§fn dir() -> PathBuf
fn dir() -> PathBuf
Return the path to the sys objects, the full path of a folder in /sys/class
Source§fn from_path(path: &Path) -> Result<Self>
fn from_path(path: &Path) -> Result<Self>
Create a sys object from a path, checking it for validity
Source§fn iter() -> Box<dyn Iterator<Item = Result<Self>>>where
Self: 'static,
fn iter() -> Box<dyn Iterator<Item = Result<Self>>>where
Self: 'static,
Retrieve all of the object instances of a sys class, with a boxed iterator
Source§fn read_file<P: AsRef<Path>>(&self, name: P) -> Result<String>
fn read_file<P: AsRef<Path>>(&self, name: P) -> Result<String>
Read a file underneath the sys object
Source§fn parse_file<F: FromStr, P: AsRef<Path>>(&self, name: P) -> Result<F>
fn parse_file<F: FromStr, P: AsRef<Path>>(&self, name: P) -> Result<F>
Parse a number from a file underneath the sys object
Auto Trait Implementations§
impl Freeze for Backlight
impl RefUnwindSafe for Backlight
impl Send for Backlight
impl Sync for Backlight
impl Unpin for Backlight
impl UnwindSafe for Backlight
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more