pub struct MessageCopyOptions {
pub send_copy: bool,
pub replace_caption: bool,
pub new_caption: Option<FormattedText>,
}
Expand description
Options to be used when a message content is copied without reference to the original sender. Service messages, messages with messageInvoice, messagePremiumGiveaway, or messagePremiumGiveawayWinners content can’t be copied
Fields§
§send_copy: bool
True, if content of the message needs to be copied without reference to the original sender. Always true if the message is forwarded to a secret chat or is local
replace_caption: bool
True, if media caption of the message copy needs to be replaced. Ignored if send_copy is false
new_caption: Option<FormattedText>
New message caption; pass null to copy message without caption. Ignored if replace_caption is false
Trait Implementations§
Source§impl Clone for MessageCopyOptions
impl Clone for MessageCopyOptions
Source§fn clone(&self) -> MessageCopyOptions
fn clone(&self) -> MessageCopyOptions
Returns a duplicate 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 MessageCopyOptions
impl Debug for MessageCopyOptions
Source§impl Default for MessageCopyOptions
impl Default for MessageCopyOptions
Source§fn default() -> MessageCopyOptions
fn default() -> MessageCopyOptions
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for MessageCopyOptions
impl<'de> Deserialize<'de> for MessageCopyOptions
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 PartialEq for MessageCopyOptions
impl PartialEq for MessageCopyOptions
Source§impl Serialize for MessageCopyOptions
impl Serialize for MessageCopyOptions
impl StructuralPartialEq for MessageCopyOptions
Auto Trait Implementations§
impl Freeze for MessageCopyOptions
impl RefUnwindSafe for MessageCopyOptions
impl Send for MessageCopyOptions
impl Sync for MessageCopyOptions
impl Unpin for MessageCopyOptions
impl UnwindSafe for MessageCopyOptions
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