Struct tg_bot_models::KeyboardButton [−][src]
pub struct KeyboardButton { pub text: String, pub request_contact: Option<bool>, pub request_location: Option<bool>, }
This object represents one button of the reply keyboard. For simple text buttons String can be used instead of this object to specify text of the button. Optional fields are mutually exclusive.
Fields
text: String
Text of the button. If none of the optional fields are used, it will be sent as a message when the button is pressed
request_contact: Option<bool>
Optional. If True, the user's phone number will be sent as a contact when the button is pressed. Available in private chats only
request_location: Option<bool>
Optional. If True, the user's current location will be sent when the button is pressed. Available in private chats only
Trait Implementations
impl Debug for KeyboardButton
[src]
impl Debug for KeyboardButton
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl Clone for KeyboardButton
[src]
impl Clone for KeyboardButton
fn clone(&self) -> KeyboardButton
[src]
fn clone(&self) -> KeyboardButton
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl PartialEq for KeyboardButton
[src]
impl PartialEq for KeyboardButton
fn eq(&self, other: &KeyboardButton) -> bool
[src]
fn eq(&self, other: &KeyboardButton) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &KeyboardButton) -> bool
[src]
fn ne(&self, other: &KeyboardButton) -> bool
This method tests for !=
.
impl PartialOrd for KeyboardButton
[src]
impl PartialOrd for KeyboardButton
fn partial_cmp(&self, other: &KeyboardButton) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &KeyboardButton) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &KeyboardButton) -> bool
[src]
fn lt(&self, other: &KeyboardButton) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &KeyboardButton) -> bool
[src]
fn le(&self, other: &KeyboardButton) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &KeyboardButton) -> bool
[src]
fn gt(&self, other: &KeyboardButton) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &KeyboardButton) -> bool
[src]
fn ge(&self, other: &KeyboardButton) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
Auto Trait Implementations
impl Send for KeyboardButton
impl Send for KeyboardButton
impl Sync for KeyboardButton
impl Sync for KeyboardButton