pub struct SecretSendContent {
pub request_id: OwnedTransactionId,
pub secret: String,
pub secret_name: Option<SecretName>,
/* private fields */
}
Expand description
The m.secret.send
event content.
Sent by a client to share a secret with another device, in response to an
m.secret.request
event. It must be encrypted as an m.room.encrypted
event, then sent as a to-device event.
Fields§
§request_id: OwnedTransactionId
The ID of the request that this a response to.
secret: String
The contents of the secret.
secret_name: Option<SecretName>
The name of the secret, typically not part of the event but can be
inserted when processing m.secret.send
events so other event consumers
know which secret this event contains.
Implementations§
Source§impl SecretSendContent
impl SecretSendContent
Sourcepub fn new(request_id: OwnedTransactionId, secret: String) -> Self
pub fn new(request_id: OwnedTransactionId, secret: String) -> Self
Create a new m.secret.send
content.
Trait Implementations§
Source§impl Clone for SecretSendContent
impl Clone for SecretSendContent
Source§fn clone(&self) -> SecretSendContent
fn clone(&self) -> SecretSendContent
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 Debug for SecretSendContent
Available on non-tarpaulin_include
only.
impl Debug for SecretSendContent
Available on non-
tarpaulin_include
only.Source§impl<'de> Deserialize<'de> for SecretSendContent
impl<'de> Deserialize<'de> for SecretSendContent
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 Drop for SecretSendContent
impl Drop for SecretSendContent
Source§impl EventType for SecretSendContent
impl EventType for SecretSendContent
Source§const EVENT_TYPE: &'static str = "m.secret.send"
const EVENT_TYPE: &'static str = "m.secret.send"
The event type of the event content.
Source§fn event_type(&self) -> &'static str
fn event_type(&self) -> &'static str
Get the event type of the event content. Read more
Source§impl Serialize for SecretSendContent
impl Serialize for SecretSendContent
Auto Trait Implementations§
impl Freeze for SecretSendContent
impl RefUnwindSafe for SecretSendContent
impl Send for SecretSendContent
impl Sync for SecretSendContent
impl Unpin for SecretSendContent
impl UnwindSafe for SecretSendContent
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§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,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§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