Struct matrix_sdk_crypto::types::Signatures
source · [−]pub struct Signatures(_);
Expand description
Signatures for a signed object.
Implementations
sourceimpl Signatures
impl Signatures
sourcepub fn add_signature(
&mut self,
signer: OwnedUserId,
key_id: OwnedDeviceKeyId,
signature: Ed25519Signature
) -> Option<Result<Signature, InvalidSignature>>
pub fn add_signature(
&mut self,
signer: OwnedUserId,
key_id: OwnedDeviceKeyId,
signature: Ed25519Signature
) -> Option<Result<Signature, InvalidSignature>>
Add the given signature from the given signer and the given key_id to the collection.
sourcepub fn get_signature(
&self,
signer: &UserId,
key_id: &DeviceKeyId
) -> Option<Ed25519Signature>
pub fn get_signature(
&self,
signer: &UserId,
key_id: &DeviceKeyId
) -> Option<Ed25519Signature>
Try to find an Ed25519 signature from the given signer with the given key id.
sourcepub fn get(
&self,
signer: &UserId
) -> Option<&BTreeMap<OwnedDeviceKeyId, Result<Signature, InvalidSignature>>>
pub fn get(
&self,
signer: &UserId
) -> Option<&BTreeMap<OwnedDeviceKeyId, Result<Signature, InvalidSignature>>>
Get the map of signatures that belong to the given user.
sourcepub fn is_empty(&self) -> bool
pub fn is_empty(&self) -> bool
Do we hold any signatures or is our collection completely empty.
sourcepub fn signature_count(&self) -> usize
pub fn signature_count(&self) -> usize
How many signatures do we currently hold.
Trait Implementations
sourceimpl Clone for Signatures
impl Clone for Signatures
sourcefn clone(&self) -> Signatures
fn clone(&self) -> Signatures
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for Signatures
impl Debug for Signatures
sourceimpl Default for Signatures
impl Default for Signatures
sourceimpl<'de> Deserialize<'de> for Signatures
impl<'de> Deserialize<'de> for Signatures
sourcefn 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
sourceimpl IntoIterator for Signatures
impl IntoIterator for Signatures
type Item = (OwnedUserId, BTreeMap<OwnedDeviceKeyId, Result<Signature, InvalidSignature>, Global>)
type Item = (OwnedUserId, BTreeMap<OwnedDeviceKeyId, Result<Signature, InvalidSignature>, Global>)
The type of the elements being iterated over.
type IntoIter = IntoIter<OwnedUserId, BTreeMap<OwnedDeviceKeyId, Result<Signature, InvalidSignature>, Global>, Global>
type IntoIter = IntoIter<OwnedUserId, BTreeMap<OwnedDeviceKeyId, Result<Signature, InvalidSignature>, Global>, Global>
Which kind of iterator are we turning this into?
sourceimpl PartialEq<Signatures> for Signatures
impl PartialEq<Signatures> for Signatures
sourcefn eq(&self, other: &Signatures) -> bool
fn eq(&self, other: &Signatures) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &Signatures) -> bool
fn ne(&self, other: &Signatures) -> bool
This method tests for !=
.
sourceimpl Serialize for Signatures
impl Serialize for Signatures
impl Eq for Signatures
impl StructuralEq for Signatures
impl StructuralPartialEq for Signatures
Auto Trait Implementations
impl RefUnwindSafe for Signatures
impl Send for Signatures
impl Sync for Signatures
impl Unpin for Signatures
impl UnwindSafe for Signatures
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<Q, K> Equivalent<K> for Q where
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Q where
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
sourcefn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to key
and return true
if they are equal.
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more