pub struct AnswerInlineQuery {
pub inline_query_id: InlineQueryId,
pub results: Vec<InlineQueryResult>,
pub cache_time: Option<u32>,
pub is_personal: Option<bool>,
pub next_offset: Option<String>,
pub button: Option<InlineQueryResultsButton>,
}Expand description
Use this method to send answers to an inline query. On success, True is returned. No more than 50 results per query are allowed.
Fields§
§inline_query_id: InlineQueryIdUnique identifier for the answered query
results: Vec<InlineQueryResult>A JSON-serialized array of results for the inline query
cache_time: Option<u32>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.
A JSON-serialized object describing a button to be shown above inline query results
Implementations§
Source§impl AnswerInlineQuery
impl AnswerInlineQuery
pub fn new( inline_query_id: InlineQueryId, results: impl IntoIterator<Item = InlineQueryResult>, ) -> Self
Trait Implementations§
Source§impl Clone for AnswerInlineQuery
impl Clone for AnswerInlineQuery
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for AnswerInlineQuery
impl Debug for AnswerInlineQuery
Source§impl PartialEq for AnswerInlineQuery
impl PartialEq for AnswerInlineQuery
Source§impl Payload for AnswerInlineQuery
impl Payload for AnswerInlineQuery
Source§fn timeout_hint(&self) -> Option<Duration>
fn timeout_hint(&self) -> Option<Duration>
GetUpdates with
big timeout), the minimum timeout that should be used.Source§impl Serialize for AnswerInlineQuery
impl Serialize for AnswerInlineQuery
impl StructuralPartialEq for AnswerInlineQuery
Auto Trait Implementations§
impl Freeze for AnswerInlineQuery
impl RefUnwindSafe for AnswerInlineQuery
impl Send for AnswerInlineQuery
impl Sync for AnswerInlineQuery
impl Unpin for AnswerInlineQuery
impl UnwindSafe for AnswerInlineQuery
Blanket Implementations§
Source§impl<P> AnswerInlineQuerySetters for Pwhere
P: HasPayload<Payload = AnswerInlineQuery>,
impl<P> AnswerInlineQuerySetters for Pwhere
P: HasPayload<Payload = AnswerInlineQuery>,
Source§fn inline_query_id(self, value: InlineQueryId) -> Self
fn inline_query_id(self, value: InlineQueryId) -> Self
inline_query_id field.Source§fn results<T>(self, value: T) -> Selfwhere
T: IntoIterator<Item = InlineQueryResult>,
fn results<T>(self, value: T) -> Selfwhere
T: IntoIterator<Item = InlineQueryResult>,
results field.Source§fn cache_time(self, value: u32) -> Self
fn cache_time(self, value: u32) -> Self
cache_time field.Source§fn is_personal(self, value: bool) -> Self
fn is_personal(self, value: bool) -> Self
is_personal field.Source§fn next_offset<T>(self, value: T) -> Self
fn next_offset<T>(self, value: T) -> Self
next_offset field.button field.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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Erasable for T
impl<T> Erasable for T
Source§impl<P> HasPayload for Pwhere
P: Payload,
impl<P> HasPayload for Pwhere
P: Payload,
Source§fn payload_mut(&mut self) -> &mut <P as HasPayload>::Payload
fn payload_mut(&mut self) -> &mut <P as HasPayload>::Payload
Source§fn payload_ref(&self) -> &<P as HasPayload>::Payload
fn payload_ref(&self) -> &<P as HasPayload>::Payload
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more