Struct telegram_bot2::models::SendMessageBuilder
source · pub struct SendMessageBuilder { /* private fields */ }Expand description
Builder for the SendMessage structure
Implementations§
source§impl SendMessageBuilder
impl SendMessageBuilder
sourcepub fn new(chat_id: ChatId, text: String) -> Self
pub fn new(chat_id: ChatId, text: String) -> Self
Instantiate the builder with the fields chat_id, message_thread_id, text, parse_mode, entities, disable_web_page_preview, disable_notification, protect_content, reply_to_message_id, allow_sending_without_reply, reply_markup
sourcepub fn message_thread_id(self, val: i64) -> Self
pub fn message_thread_id(self, val: i64) -> Self
Set the field message_thread_id to the given value
sourcepub fn parse_mode(self, val: String) -> Self
pub fn parse_mode(self, val: String) -> Self
Set the field parse_mode to the given value
sourcepub fn entities(self, val: Vec<MessageEntity>) -> Self
pub fn entities(self, val: Vec<MessageEntity>) -> Self
Set the field entities to the given value
sourcepub fn disable_web_page_preview(self, val: bool) -> Self
pub fn disable_web_page_preview(self, val: bool) -> Self
Set the field disable_web_page_preview to the given value
sourcepub fn disable_notification(self, val: bool) -> Self
pub fn disable_notification(self, val: bool) -> Self
Set the field disable_notification to the given value
sourcepub fn protect_content(self, val: bool) -> Self
pub fn protect_content(self, val: bool) -> Self
Set the field protect_content to the given value
sourcepub fn reply_to_message_id(self, val: i64) -> Self
pub fn reply_to_message_id(self, val: i64) -> Self
Set the field reply_to_message_id to the given value
sourcepub fn allow_sending_without_reply(self, val: bool) -> Self
pub fn allow_sending_without_reply(self, val: bool) -> Self
Set the field allow_sending_without_reply to the given value
sourcepub fn reply_markup(self, val: ReplyMarkup) -> Self
pub fn reply_markup(self, val: ReplyMarkup) -> Self
Set the field reply_markup to the given value
Trait Implementations§
source§impl Builder for SendMessageBuilder
impl Builder for SendMessageBuilder
§type Value = SendMessage
type Value = SendMessage
Type to be built