pub enum KeyboardButtonType {
Text,
RequestPhoneNumber,
RequestLocation,
RequestPoll(KeyboardButtonTypeRequestPoll),
RequestUsers(KeyboardButtonTypeRequestUsers),
RequestChat(KeyboardButtonTypeRequestChat),
WebApp(KeyboardButtonTypeWebApp),
}
Variants§
Text
A simple button, with text that must be sent when the button is pressed
RequestPhoneNumber
A button that sends the user’s phone number when pressed; available only in private chats
RequestLocation
A button that sends the user’s location when pressed; available only in private chats
RequestPoll(KeyboardButtonTypeRequestPoll)
A button that allows the user to create and send a poll when pressed; available only in private chats
RequestUsers(KeyboardButtonTypeRequestUsers)
A button that requests users to be shared by the current user; available only in private chats. Use the method shareUsersWithBot to complete the request
RequestChat(KeyboardButtonTypeRequestChat)
A button that requests a chat to be shared by the current user; available only in private chats. Use the method shareChatWithBot to complete the request
WebApp(KeyboardButtonTypeWebApp)
A button that opens a Web App by calling getWebAppUrl
Trait Implementations§
Source§impl Clone for KeyboardButtonType
impl Clone for KeyboardButtonType
Source§fn clone(&self) -> KeyboardButtonType
fn clone(&self) -> KeyboardButtonType
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 KeyboardButtonType
impl Debug for KeyboardButtonType
Source§impl<'de> Deserialize<'de> for KeyboardButtonType
impl<'de> Deserialize<'de> for KeyboardButtonType
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 KeyboardButtonType
impl PartialEq for KeyboardButtonType
Source§impl Serialize for KeyboardButtonType
impl Serialize for KeyboardButtonType
impl StructuralPartialEq for KeyboardButtonType
Auto Trait Implementations§
impl Freeze for KeyboardButtonType
impl RefUnwindSafe for KeyboardButtonType
impl Send for KeyboardButtonType
impl Sync for KeyboardButtonType
impl Unpin for KeyboardButtonType
impl UnwindSafe for KeyboardButtonType
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