Struct telexide::api::types::AnswerInlineQuery
source · pub struct AnswerInlineQuery {
pub inline_query_id: String,
pub results: Vec<InlineQueryResult>,
pub cache_time: Option<i64>,
pub is_personal: Option<bool>,
pub next_offset: Option<String>,
pub button: Option<InlineQueryResultsButton>,
}
Expand description
struct for holding data needed to call
answer_inline_query
Fields§
§inline_query_id: String
Unique identifier for the answered query
results: Vec<InlineQueryResult>
A vec of results for the inline query
cache_time: Option<i64>
The maximum amount of time in seconds that the result of the inline query may be cached on the server. Defaults to 300.
is_personal: Option<bool>
Pass True, if results may be cached on the server side only for the user that sent the query. By default, results may be returned to any user who sends the same query
next_offset: Option<String>
Pass the offset that a client should send in the next query with the same text to receive more results. Pass an empty string if there are no more results or if you don‘t support pagination. Offset length can’t exceed 64 bytes.
An object describing a button to be shown above inline query results
Implementations§
source§impl AnswerInlineQuery
impl AnswerInlineQuery
pub fn new( inline_query_id: impl ToString, results: Vec<InlineQueryResult> ) -> Self
pub fn set_cache_time(&mut self, cache_time: i64) -> &mut Self
pub fn set_is_personal(&mut self, is_personal: bool) -> &mut Self
pub fn set_next_offset(&mut self, next_offset: impl ToString) -> &mut Self
Trait Implementations§
source§impl Clone for AnswerInlineQuery
impl Clone for AnswerInlineQuery
source§fn clone(&self) -> AnswerInlineQuery
fn clone(&self) -> AnswerInlineQuery
Returns a copy 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 AnswerInlineQuery
impl Debug for AnswerInlineQuery
source§impl<'de> Deserialize<'de> for AnswerInlineQuery
impl<'de> Deserialize<'de> for AnswerInlineQuery
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 AnswerInlineQuery
impl PartialEq for AnswerInlineQuery
source§fn eq(&self, other: &AnswerInlineQuery) -> bool
fn eq(&self, other: &AnswerInlineQuery) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for AnswerInlineQuery
impl Serialize for AnswerInlineQuery
impl StructuralPartialEq for AnswerInlineQuery
Auto Trait Implementations§
impl RefUnwindSafe for AnswerInlineQuery
impl Send for AnswerInlineQuery
impl Sync for AnswerInlineQuery
impl Unpin for AnswerInlineQuery
impl UnwindSafe for AnswerInlineQuery
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