#[non_exhaustive]pub struct KeyVerificationRequestEventContent {
pub body: String,
pub formatted: Option<FormattedBody>,
pub methods: Vec<VerificationMethod>,
pub from_device: OwnedDeviceId,
pub to: OwnedUserId,
}
Expand description
The payload for a key verification request message.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.body: String
A fallback message to alert users that their client does not support the key verification framework.
Clients that do support the key verification framework should hide the body and instead present the user with an interface to accept or reject the key verification.
formatted: Option<FormattedBody>
Formatted form of the body
.
As with the body
, clients that do support the key verification framework should hide the
formatted body and instead present the user with an interface to accept or reject the key
verification.
methods: Vec<VerificationMethod>
The verification methods supported by the sender.
from_device: OwnedDeviceId
The device ID which is initiating the request.
to: OwnedUserId
The user ID which should receive the request.
Users should only respond to verification requests if they are named in this field. Users
who are not named in this field and who did not send this event should ignore all other
events that have a m.reference
relationship with this event.
Implementations§
Source§impl KeyVerificationRequestEventContent
impl KeyVerificationRequestEventContent
Sourcepub fn new(
body: String,
methods: Vec<VerificationMethod>,
from_device: OwnedDeviceId,
to: OwnedUserId,
) -> Self
pub fn new( body: String, methods: Vec<VerificationMethod>, from_device: OwnedDeviceId, to: OwnedUserId, ) -> Self
Creates a new KeyVerificationRequestEventContent
with the given body, method, device
and user ID.
Trait Implementations§
Source§impl Clone for KeyVerificationRequestEventContent
impl Clone for KeyVerificationRequestEventContent
Source§fn clone(&self) -> KeyVerificationRequestEventContent
fn clone(&self) -> KeyVerificationRequestEventContent
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more