Enum libcryptsetup_rs::CryptTokenInfo
source · pub enum CryptTokenInfo {
Invalid,
Inactive,
Internal(String),
InternalUnknown(String),
External(String),
ExternalUnknown(String),
}
Expand description
Type representing the token status. This type wraps the CRYPT_TOKEN_*
values and the optional corresponding token type as a string.
Variants§
Invalid
Token invalid
Inactive
Token is free (empty)
Internal(String)
Active internal token with driver
InternalUnknown(String)
Active internal token (reserved name) with missing token driver
External(String)
Active external (user defined) token with driver
ExternalUnknown(String)
Active external (user defined) token with missing token driver
Implementations§
source§impl CryptTokenInfo
impl CryptTokenInfo
sourcepub fn from_status(
code: c_uint,
type_: Option<String>
) -> Result<Self, LibcryptErr>
pub fn from_status( code: c_uint, type_: Option<String> ) -> Result<Self, LibcryptErr>
Convert a token status code into CryptTokenInfo
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for CryptTokenInfo
impl Send for CryptTokenInfo
impl Sync for CryptTokenInfo
impl Unpin for CryptTokenInfo
impl UnwindSafe for CryptTokenInfo
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