pub enum UnlockOutcome {
Unlocked {
credential: String,
kind: CredentialKind,
slot_index: usize,
filename: Option<String>,
plaintext_size: u64,
},
Locked,
}Expand description
解锁尝试的结果。
Variants§
Unlocked
某个凭据成功解开。
Fields
§
kind: CredentialKind凭据类型。
Locked
是 .omy 文件,但当前所有凭据都打不开。
注意:这不代表文件损坏或密码错误——它可能属于另一个密码集。 UI 应表述为「不属于当前密码」而非「密码错误」。
Implementations§
Source§impl UnlockOutcome
impl UnlockOutcome
Sourcepub const fn is_unlocked(&self) -> bool
pub const fn is_unlocked(&self) -> bool
是否成功解锁。
Trait Implementations§
Auto Trait Implementations§
impl Forget for UnlockOutcome
impl Freeze for UnlockOutcome
impl RefUnwindSafe for UnlockOutcome
impl Send for UnlockOutcome
impl Sync for UnlockOutcome
impl Unpin for UnlockOutcome
impl UnsafeUnpin for UnlockOutcome
impl UnwindSafe for UnlockOutcome
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