pub trait Callback: Callback {
fn answer(&self, action: Option<CallbackAction>) -> AnswerCallbackQuery<'_> { ... }
fn ignore(&self) -> AnswerCallbackQuery<'_> { ... }
fn open_url(&self, url: impl Into<String>) -> AnswerCallbackQuery<'_> { ... }
fn notify(&self, text: impl Into<String>) -> AnswerCallbackQuery<'_> { ... }
fn alert(&self, text: impl Into<String>) -> AnswerCallbackQuery<'_> { ... }
}
Expand description
Provides methods appliable to callback queries.
Provided Methods§
sourcefn answer(&self, action: Option<CallbackAction>) -> AnswerCallbackQuery<'_>
fn answer(&self, action: Option<CallbackAction>) -> AnswerCallbackQuery<'_>
sourcefn ignore(&self) -> AnswerCallbackQuery<'_>
fn ignore(&self) -> AnswerCallbackQuery<'_>
Answers the query without any action.
sourcefn open_url(&self, url: impl Into<String>) -> AnswerCallbackQuery<'_>
fn open_url(&self, url: impl Into<String>) -> AnswerCallbackQuery<'_>
Opens a URL.
sourcefn notify(&self, text: impl Into<String>) -> AnswerCallbackQuery<'_>
fn notify(&self, text: impl Into<String>) -> AnswerCallbackQuery<'_>
Shows a notification to the user.
sourcefn alert(&self, text: impl Into<String>) -> AnswerCallbackQuery<'_>
fn alert(&self, text: impl Into<String>) -> AnswerCallbackQuery<'_>
Shows an alert to the user.