[][src]Struct telexide::model::KeyboardButton

pub struct KeyboardButton {
    pub text: String,
    pub request_contact: bool,
    pub request_location: bool,
    pub request_poll: Option<KeyboardButtonPollType>,
}

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.

Note: Optional fields request_contact, request_location, and request_poll 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: bool

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: bool

If true, the user's current location will be sent when the button is pressed. Available in private chats only

request_poll: Option<KeyboardButtonPollType>

If specified, the user will be asked to create a poll and send it to the bot when the button is pressed. Available in private chats only

Trait Implementations

impl Clone for KeyboardButton[src]

impl Debug for KeyboardButton[src]

impl<'de> Deserialize<'de> for KeyboardButton[src]

impl PartialEq<KeyboardButton> for KeyboardButton[src]

impl Serialize for KeyboardButton[src]

impl StructuralPartialEq for KeyboardButton[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> CloneAny for T where
    T: Clone + Any
[src]

impl<T> DebugAny for T where
    T: Any + Debug
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> UnsafeAny for T where
    T: Any