Struct matrix_sdk_crypto::types::SigningKeys
source · pub struct SigningKeys<T: Ord>(/* private fields */);
Expand description
A collection of signing keys, a map from the key id to the signing key.
Implementations§
source§impl<T: Ord> SigningKeys<T>
impl<T: Ord> SigningKeys<T>
sourcepub fn insert(&mut self, key_id: T, key: SigningKey) -> Option<SigningKey>
pub fn insert(&mut self, key_id: T, key: SigningKey) -> Option<SigningKey>
Insert a SigningKey
into the collection.
sourcepub fn get<Q>(&self, key_id: &Q) -> Option<&SigningKey>
pub fn get<Q>(&self, key_id: &Q) -> Option<&SigningKey>
Get a SigningKey
with the given DeviceKeyId
.
sourcepub fn iter(&self) -> Iter<'_, T, SigningKey>
pub fn iter(&self) -> Iter<'_, T, SigningKey>
Create an iterator over the SigningKey
s in this collection.
Trait Implementations§
source§impl<T: Clone + Ord> Clone for SigningKeys<T>
impl<T: Clone + Ord> Clone for SigningKeys<T>
source§fn clone(&self) -> SigningKeys<T>
fn clone(&self) -> SigningKeys<T>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<T: Ord> Default for SigningKeys<T>
impl<T: Ord> Default for SigningKeys<T>
source§impl<'de, T: Algorithm + Ord + Deserialize<'de>> Deserialize<'de> for SigningKeys<T>
impl<'de, T: Algorithm + Ord + Deserialize<'de>> Deserialize<'de> for SigningKeys<T>
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
source§impl<K: Ord, const N: usize> From<[(K, SigningKey); N]> for SigningKeys<K>
impl<K: Ord, const N: usize> From<[(K, SigningKey); N]> for SigningKeys<K>
source§fn from(v: [(K, SigningKey); N]) -> Self
fn from(v: [(K, SigningKey); N]) -> Self
Converts to this type from the input type.
source§impl<K: Ord> FromIterator<(K, SigningKey)> for SigningKeys<K>
impl<K: Ord> FromIterator<(K, SigningKey)> for SigningKeys<K>
source§fn from_iter<T: IntoIterator<Item = (K, SigningKey)>>(iter: T) -> Self
fn from_iter<T: IntoIterator<Item = (K, SigningKey)>>(iter: T) -> Self
Creates a value from an iterator. Read more
source§impl<T: Ord> IntoIterator for SigningKeys<T>
impl<T: Ord> IntoIterator for SigningKeys<T>
source§impl<T: PartialEq + Ord> PartialEq for SigningKeys<T>
impl<T: PartialEq + Ord> PartialEq for SigningKeys<T>
source§fn eq(&self, other: &SigningKeys<T>) -> bool
fn eq(&self, other: &SigningKeys<T>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl<T: Eq + Ord> Eq for SigningKeys<T>
impl<T: Ord> StructuralPartialEq for SigningKeys<T>
Auto Trait Implementations§
impl<T> Freeze for SigningKeys<T>
impl<T> RefUnwindSafe for SigningKeys<T>where
T: RefUnwindSafe,
impl<T> Send for SigningKeys<T>where
T: Send,
impl<T> Sync for SigningKeys<T>where
T: Sync,
impl<T> Unpin for SigningKeys<T>
impl<T> UnwindSafe for SigningKeys<T>where
T: RefUnwindSafe,
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)§impl<T> CompatExt for T
impl<T> CompatExt for T
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.source§impl<T, UT> HandleAlloc<UT> for T
impl<T, UT> HandleAlloc<UT> for T
source§fn consume_handle(handle: Handle) -> Arc<T>
fn consume_handle(handle: Handle) -> Arc<T>
Consume a handle, getting back the initial
Arc<>
source§impl<T, W> HasTypeWitness<W> for Twhere
W: MakeTypeWitness<Arg = T>,
T: ?Sized,
impl<T, W> HasTypeWitness<W> for Twhere
W: MakeTypeWitness<Arg = T>,
T: ?Sized,
source§impl<T> Identity for Twhere
T: ?Sized,
impl<T> Identity for Twhere
T: ?Sized,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more