Struct matrix_sdk_base::ruma::events::key::verification::key::KeyVerificationKeyEventContent
#[non_exhaustive]pub struct KeyVerificationKeyEventContent {
pub key: Base64,
pub relates_to: Reference,
}
Expand description
The content of an in-room m.key.verification.key
event.
Sends the ephemeral public key for a device to the partner device.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.key: Base64
The device’s ephemeral public key, encoded as unpadded base64.
relates_to: Reference
Information about the related event.
Implementations§
§impl KeyVerificationKeyEventContent
impl KeyVerificationKeyEventContent
pub fn new(key: Base64, relates_to: Reference) -> KeyVerificationKeyEventContent
pub fn new(key: Base64, relates_to: Reference) -> KeyVerificationKeyEventContent
Creates a new KeyVerificationKeyEventContent
with the given key and reference.
Trait Implementations§
§impl Clone for KeyVerificationKeyEventContent
impl Clone for KeyVerificationKeyEventContent
§fn clone(&self) -> KeyVerificationKeyEventContent
fn clone(&self) -> KeyVerificationKeyEventContent
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 more§impl Debug for KeyVerificationKeyEventContent
impl Debug for KeyVerificationKeyEventContent
§impl<'de> Deserialize<'de> for KeyVerificationKeyEventContent
impl<'de> Deserialize<'de> for KeyVerificationKeyEventContent
§fn deserialize<__D>(
__deserializer: __D
) -> Result<KeyVerificationKeyEventContent, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D
) -> Result<KeyVerificationKeyEventContent, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
§impl EventContent for KeyVerificationKeyEventContent
impl EventContent for KeyVerificationKeyEventContent
§type EventType = MessageLikeEventType
type EventType = MessageLikeEventType
The Rust enum for the event kind’s known types.
§fn event_type(
&self
) -> <KeyVerificationKeyEventContent as EventContent>::EventType
fn event_type( &self ) -> <KeyVerificationKeyEventContent as EventContent>::EventType
Get the event’s type, like
m.room.message
.§impl From<KeyVerificationKeyEventContent> for AnyMessageLikeEventContent
impl From<KeyVerificationKeyEventContent> for AnyMessageLikeEventContent
§fn from(c: KeyVerificationKeyEventContent) -> AnyMessageLikeEventContent
fn from(c: KeyVerificationKeyEventContent) -> AnyMessageLikeEventContent
Converts to this type from the input type.
§impl RedactContent for KeyVerificationKeyEventContent
impl RedactContent for KeyVerificationKeyEventContent
§type Redacted = RedactedKeyVerificationKeyEventContent
type Redacted = RedactedKeyVerificationKeyEventContent
The redacted form of the event’s content.
§fn redact(
self,
version: &RoomVersionId
) -> RedactedKeyVerificationKeyEventContent
fn redact( self, version: &RoomVersionId ) -> RedactedKeyVerificationKeyEventContent
Transform
self
into a redacted form (removing most or all fields) according to the spec. Read more§impl Serialize for KeyVerificationKeyEventContent
impl Serialize for KeyVerificationKeyEventContent
§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,
Serialize this value into the given Serde serializer. Read more
impl MessageLikeEventContent for KeyVerificationKeyEventContent
Auto Trait Implementations§
impl RefUnwindSafe for KeyVerificationKeyEventContent
impl Send for KeyVerificationKeyEventContent
impl Sync for KeyVerificationKeyEventContent
impl Unpin for KeyVerificationKeyEventContent
impl UnwindSafe for KeyVerificationKeyEventContent
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