pub struct MediaSendOptions {
pub media_metadata: Option<MediaMetadata>,
pub caption: Option<String>,
pub reply_to_msg: Option<String>,
pub reply_context: Option<ReplyContext>,
pub forward_info: Option<ForwardInfo>,
pub file_id: Option<String>,
}Expand description
Options for OfflineProtocol::send_media_with: the chunk-0 media
metadata (as on send_media), plus the rich fields introduced with the
sealed rich payload and an optional caller-supplied file_id.
The rich fields (caption, reply_to_msg, reply_context,
forward_info) only ever travel inside the MLS-sealed chunk-0 plaintext
(v2 media envelope), and only toward recipients whose key package
advertised rich_versions support. Toward anyone else — including every
plaintext (encryption opt-out) transfer — they are silently dropped,
never sent cleartext, so the transfer degrades to what plain
send_media sends.
Fields§
§media_metadata: Option<MediaMetadata>Media metadata delivered with chunk 0 (as on send_media).
caption: Option<String>Caption text, delivered sealed-only.
reply_to_msg: Option<String>ID of the message this media replies to, delivered sealed-only.
reply_context: Option<ReplyContext>Quoted-reply context, delivered sealed-only.
forward_info: Option<ForwardInfo>Forward attribution, delivered sealed-only.
file_id: Option<String>Caller-supplied file id for the transfer (minted when absent). Must
not collide with an active outbound transfer; bounded to the wire
file_id field limit.
Trait Implementations§
Source§impl Clone for MediaSendOptions
impl Clone for MediaSendOptions
Source§fn clone(&self) -> MediaSendOptions
fn clone(&self) -> MediaSendOptions
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for MediaSendOptions
impl Debug for MediaSendOptions
Source§impl Default for MediaSendOptions
impl Default for MediaSendOptions
Source§fn default() -> MediaSendOptions
fn default() -> MediaSendOptions
Auto Trait Implementations§
impl Freeze for MediaSendOptions
impl RefUnwindSafe for MediaSendOptions
impl Send for MediaSendOptions
impl Sync for MediaSendOptions
impl Unpin for MediaSendOptions
impl UnsafeUnpin for MediaSendOptions
impl UnwindSafe for MediaSendOptions
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,
Source§impl<T> Declassify for T
impl<T> Declassify for T
type Declassified = T
fn declassify(self) -> T
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> ⓘ
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