pub struct KeychainEntry { /* private fields */ }Expand description
Wraps a generic-password identity used with SecItem queries.
Implementations§
Source§impl KeychainEntry
impl KeychainEntry
Sourcepub fn new(account: impl Into<String>, service: impl Into<String>) -> Self
pub fn new(account: impl Into<String>, service: impl Into<String>) -> Self
Wraps the corresponding generic-password operation built on SecItem.
Sourcepub fn account(&self) -> &str
pub fn account(&self) -> &str
Wraps the corresponding generic-password operation built on SecItem.
Sourcepub fn service(&self) -> &str
pub fn service(&self) -> &str
Wraps the corresponding generic-password operation built on SecItem.
Sourcepub fn set(&self, password: &str) -> Result<()>
pub fn set(&self, password: &str) -> Result<()>
Wraps the corresponding generic-password operation built on SecItem.
Trait Implementations§
Source§impl Clone for KeychainEntry
impl Clone for KeychainEntry
Source§fn clone(&self) -> KeychainEntry
fn clone(&self) -> KeychainEntry
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for KeychainEntry
impl Debug for KeychainEntry
Source§impl Hash for KeychainEntry
impl Hash for KeychainEntry
Source§impl PartialEq for KeychainEntry
impl PartialEq for KeychainEntry
Source§fn eq(&self, other: &KeychainEntry) -> bool
fn eq(&self, other: &KeychainEntry) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for KeychainEntry
impl StructuralPartialEq for KeychainEntry
Auto Trait Implementations§
impl Freeze for KeychainEntry
impl RefUnwindSafe for KeychainEntry
impl Send for KeychainEntry
impl Sync for KeychainEntry
impl Unpin for KeychainEntry
impl UnsafeUnpin for KeychainEntry
impl UnwindSafe for KeychainEntry
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