Struct smbioslib::strings::SMBiosString
source · pub struct SMBiosString { /* private fields */ }
Expand description
§SMBiosString
Contains the retrival result for an SMBIOS string field.
Implementations§
source§impl SMBiosString
impl SMBiosString
sourcepub fn to_utf8_lossy(&self) -> Option<String>
pub fn to_utf8_lossy(&self) -> Option<String>
Produces a UTF-8 which includes invalid UTF-8 characters; otherwise, returns Option::None for all other conditions.
sourcepub fn ok(self) -> Option<String>
pub fn ok(self) -> Option<String>
Converts to Option<String>
consuming self, and discarding the error, if any.
sourcepub fn err(self) -> Option<SMBiosStringError>
pub fn err(self) -> Option<SMBiosStringError>
Converts to Option<SMBiosStringError>
consuming self, and discarding the success value, if any.
sourcepub const fn as_ref(&self) -> Result<&String, &SMBiosStringError>
pub const fn as_ref(&self) -> Result<&String, &SMBiosStringError>
Produces a new Result
, containing a reference into the original, leaving the original in place.
sourcepub fn as_mut(&mut self) -> Result<&mut String, &mut SMBiosStringError>
pub fn as_mut(&mut self) -> Result<&mut String, &mut SMBiosStringError>
Converts to Result<&mut String, &mut SMBiosStringError>.
Trait Implementations§
source§impl Debug for SMBiosString
impl Debug for SMBiosString
source§impl Display for SMBiosString
impl Display for SMBiosString
source§impl From<Result<String, SMBiosStringError>> for SMBiosString
impl From<Result<String, SMBiosStringError>> for SMBiosString
Auto Trait Implementations§
impl Freeze for SMBiosString
impl RefUnwindSafe for SMBiosString
impl Send for SMBiosString
impl Sync for SMBiosString
impl Unpin for SMBiosString
impl UnwindSafe for SMBiosString
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