pub struct TextSendBuilder { /* private fields */ }Expand description
Stable builder for high-level text sends on the async app facade.
Start this from AppApi::text or AppApi::reply for the common message-send path.
Implementations§
Source§impl TextSendBuilder
impl TextSendBuilder
Sourcepub fn parse_mode(self, parse_mode: ParseMode) -> Self
pub fn parse_mode(self, parse_mode: ParseMode) -> Self
Sets text parse mode.
Sourcepub fn reply_markup(self, reply_markup: impl Into<ReplyMarkup>) -> Self
pub fn reply_markup(self, reply_markup: impl Into<ReplyMarkup>) -> Self
Attaches reply markup such as an inline keyboard.
Sourcepub fn reply_parameters(self, reply_parameters: ReplyParameters) -> Self
pub fn reply_parameters(self, reply_parameters: ReplyParameters) -> Self
Sets explicit reply parameters.
Sourcepub fn reply_to_message(self, message_id: MessageId) -> Self
pub fn reply_to_message(self, message_id: MessageId) -> Self
Replies to a concrete message by id.
Sourcepub fn message_thread_id(self, message_thread_id: i64) -> Self
pub fn message_thread_id(self, message_thread_id: i64) -> Self
Targets a forum topic / message thread when applicable.
Sourcepub fn disable_notification(self, enabled: bool) -> Self
pub fn disable_notification(self, enabled: bool) -> Self
Sends silently when true.
Sourcepub fn protect_content(self, enabled: bool) -> Self
pub fn protect_content(self, enabled: bool) -> Self
Protects the sent message from forwarding and saving when true.
Sourcepub fn link_preview_options(
self,
link_preview_options: LinkPreviewOptions,
) -> Self
pub fn link_preview_options( self, link_preview_options: LinkPreviewOptions, ) -> Self
Sets Telegram link preview behavior explicitly.
Sourcepub fn disable_link_preview(self) -> Self
pub fn disable_link_preview(self) -> Self
Disables link previews for the text message.
Sourcepub fn into_request(self) -> SendMessageRequest
pub fn into_request(self) -> SendMessageRequest
Returns the typed request for lower-level reuse or inspection.
Trait Implementations§
Source§impl Clone for TextSendBuilder
impl Clone for TextSendBuilder
Source§fn clone(&self) -> TextSendBuilder
fn clone(&self) -> TextSendBuilder
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 moreAuto Trait Implementations§
impl Freeze for TextSendBuilder
impl !RefUnwindSafe for TextSendBuilder
impl Send for TextSendBuilder
impl Sync for TextSendBuilder
impl Unpin for TextSendBuilder
impl UnsafeUnpin for TextSendBuilder
impl !UnwindSafe for TextSendBuilder
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