pub struct Keyring { /* private fields */ }Expand description
Keyring for managing multiple signing identities
Implementations§
Source§impl Keyring
impl Keyring
Sourcepub fn add(&mut self, name: impl Into<String>, key: &VerifyingKey)
pub fn add(&mut self, name: impl Into<String>, key: &VerifyingKey)
Add a verifying key with a name
Sourcepub fn get(&self, name: &str) -> Result<VerifyingKey>
pub fn get(&self, name: &str) -> Result<VerifyingKey>
Sourcepub fn set_default(&mut self, name: impl Into<String>)
pub fn set_default(&mut self, name: impl Into<String>)
Set the default key
Sourcepub fn default_key(&self) -> Result<VerifyingKey>
pub fn default_key(&self) -> Result<VerifyingKey>
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Keyring
impl<'de> Deserialize<'de> for Keyring
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Keyring
impl RefUnwindSafe for Keyring
impl Send for Keyring
impl Sync for Keyring
impl Unpin for Keyring
impl UnsafeUnpin for Keyring
impl UnwindSafe for Keyring
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