Enum RoomKeyWithheldCode
#[non_exhaustive]pub enum RoomKeyWithheldCode {
Blacklisted,
Unverified,
Unauthorized,
Unavailable,
NoOlm,
}
Expand description
The possible codes for why a megolm key was not sent.
This type can hold an arbitrary string. To build this with a custom value, convert it from a
string with ::from()
/ .into()
. To check for values that are not available as a
documented variant here, use its string representation, obtained through
.as_str()
.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Blacklisted
m.blacklisted
The user or device was blacklisted.
Unverified
m.unverified
The user or device was not verified, and the sender is only sharing keys with verified users or devices.
m.unauthorised
The user or device is not allowed to have the key. For example, this could be sent in response to a key request if the user or device was not in the room when the original message was sent.
m.unavailable
Sent in reply to a key request if the device that the key is requested from does not have the requested key.
NoOlm
m.no_olm
An olm session could not be established.
Implementations§
§impl RoomKeyWithheldCode
impl RoomKeyWithheldCode
Trait Implementations§
§impl AsRef<str> for RoomKeyWithheldCode
impl AsRef<str> for RoomKeyWithheldCode
§impl Clone for RoomKeyWithheldCode
impl Clone for RoomKeyWithheldCode
§fn clone(&self) -> RoomKeyWithheldCode
fn clone(&self) -> RoomKeyWithheldCode
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more§impl Debug for RoomKeyWithheldCode
impl Debug for RoomKeyWithheldCode
§impl<'de> Deserialize<'de> for RoomKeyWithheldCode
impl<'de> Deserialize<'de> for RoomKeyWithheldCode
§fn deserialize<D>(
deserializer: D,
) -> Result<RoomKeyWithheldCode, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
fn deserialize<D>(
deserializer: D,
) -> Result<RoomKeyWithheldCode, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
§impl Display for RoomKeyWithheldCode
impl Display for RoomKeyWithheldCode
§impl<T> From<T> for RoomKeyWithheldCode
impl<T> From<T> for RoomKeyWithheldCode
§fn from(s: T) -> RoomKeyWithheldCode
fn from(s: T) -> RoomKeyWithheldCode
§impl PartialEq for RoomKeyWithheldCode
impl PartialEq for RoomKeyWithheldCode
§impl Serialize for RoomKeyWithheldCode
impl Serialize for RoomKeyWithheldCode
§fn serialize<S>(
&self,
serializer: S,
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
fn serialize<S>(
&self,
serializer: S,
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
impl Eq for RoomKeyWithheldCode
impl StructuralPartialEq for RoomKeyWithheldCode
Auto Trait Implementations§
impl Freeze for RoomKeyWithheldCode
impl RefUnwindSafe for RoomKeyWithheldCode
impl Send for RoomKeyWithheldCode
impl Sync for RoomKeyWithheldCode
impl Unpin for RoomKeyWithheldCode
impl UnwindSafe for RoomKeyWithheldCode
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§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
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>
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>
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>
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