Struct smbioslib::strings::SMBiosString
source · [−]pub struct SMBiosString { /* private fields */ }
Expand description
SMBiosString
Contains the retrival result for an SMBIOS string field.
Implementations
sourceimpl 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
sourceimpl Debug for SMBiosString
impl Debug for SMBiosString
sourceimpl Display for SMBiosString
impl Display for SMBiosString
sourceimpl From<Result<String, SMBiosStringError>> for SMBiosString
impl From<Result<String, SMBiosStringError>> for SMBiosString
sourcefn from(data: Result<String, SMBiosStringError>) -> Self
fn from(data: Result<String, SMBiosStringError>) -> Self
Converts to this type from the input type.
sourceimpl Serialize for SMBiosString
impl Serialize for SMBiosString
Auto Trait Implementations
impl RefUnwindSafe for SMBiosString
impl Send for SMBiosString
impl Sync for SMBiosString
impl Unpin for SMBiosString
impl UnwindSafe for SMBiosString
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more