Struct botapi::gen_types::InlineQueryResultArticle
source · pub struct InlineQueryResultArticle {
pub tg_type: String,
pub id: String,
pub title: String,
pub input_message_content: BoxWrapper<Unbox<InputMessageContent>>,
pub reply_markup: Option<BoxWrapper<Unbox<InlineKeyboardMarkup>>>,
pub url: Option<String>,
pub hide_url: Option<bool>,
pub description: Option<String>,
pub thumbnail_url: Option<String>,
pub thumbnail_width: Option<i64>,
pub thumbnail_height: Option<i64>,
}
Expand description
Represents a link to an article or web page.
Fields§
§tg_type: String
Type of the result, must be article
id: String
Unique identifier for this result, 1-64 Bytes
title: String
Title of the result
input_message_content: BoxWrapper<Unbox<InputMessageContent>>
Content of the message to be sent
reply_markup: Option<BoxWrapper<Unbox<InlineKeyboardMarkup>>>
Optional. Inline keyboard attached to the message
url: Option<String>
Optional. URL of the result
hide_url: Option<bool>
Optional. Pass True if you don’t want the URL to be shown in the message
description: Option<String>
Optional. Short description of the result
thumbnail_url: Option<String>
Optional. Url of the thumbnail for the result
thumbnail_width: Option<i64>
Optional. Thumbnail width
thumbnail_height: Option<i64>
Optional. Thumbnail height
Implementations§
source§impl InlineQueryResultArticle
impl InlineQueryResultArticle
pub fn noskip(self) -> NoSkipInlineQueryResultArticle
source§impl InlineQueryResultArticle
impl InlineQueryResultArticle
pub fn new<A: Into<InputMessageContent>>( id: String, title: String, input_message_content: A, ) -> Self
sourcepub fn get_tg_type<'a>(&'a self) -> &'a str
pub fn get_tg_type<'a>(&'a self) -> &'a str
Type of the result, must be article
sourcepub fn set_tg_type<'a>(&'a mut self, tg_type: String) -> &'a mut Self
pub fn set_tg_type<'a>(&'a mut self, tg_type: String) -> &'a mut Self
Type of the result, must be article
sourcepub fn set_id<'a>(&'a mut self, id: String) -> &'a mut Self
pub fn set_id<'a>(&'a mut self, id: String) -> &'a mut Self
Unique identifier for this result, 1-64 Bytes
sourcepub fn set_title<'a>(&'a mut self, title: String) -> &'a mut Self
pub fn set_title<'a>(&'a mut self, title: String) -> &'a mut Self
Title of the result
sourcepub fn get_input_message_content<'a>(&'a self) -> &'a InputMessageContent
pub fn get_input_message_content<'a>(&'a self) -> &'a InputMessageContent
Content of the message to be sent
sourcepub fn set_input_message_content<'a>(
&'a mut self,
input_message_content: InputMessageContent,
) -> &'a mut Self
pub fn set_input_message_content<'a>( &'a mut self, input_message_content: InputMessageContent, ) -> &'a mut Self
Content of the message to be sent
sourcepub fn get_reply_markup<'a>(&'a self) -> Option<&'a InlineKeyboardMarkup>
pub fn get_reply_markup<'a>(&'a self) -> Option<&'a InlineKeyboardMarkup>
Optional. Inline keyboard attached to the message
sourcepub fn set_reply_markup<'a>(
&'a mut self,
reply_markup: Option<InlineKeyboardMarkup>,
) -> &'a mut Self
pub fn set_reply_markup<'a>( &'a mut self, reply_markup: Option<InlineKeyboardMarkup>, ) -> &'a mut Self
Optional. Inline keyboard attached to the message
sourcepub fn set_url<'a>(&'a mut self, url: Option<String>) -> &'a mut Self
pub fn set_url<'a>(&'a mut self, url: Option<String>) -> &'a mut Self
Optional. URL of the result
sourcepub fn get_hide_url<'a>(&'a self) -> Option<bool>
pub fn get_hide_url<'a>(&'a self) -> Option<bool>
Optional. Pass True if you don’t want the URL to be shown in the message
sourcepub fn set_hide_url<'a>(&'a mut self, hide_url: Option<bool>) -> &'a mut Self
pub fn set_hide_url<'a>(&'a mut self, hide_url: Option<bool>) -> &'a mut Self
Optional. Pass True if you don’t want the URL to be shown in the message
sourcepub fn get_description<'a>(&'a self) -> Option<&'a str>
pub fn get_description<'a>(&'a self) -> Option<&'a str>
Optional. Short description of the result
sourcepub fn set_description<'a>(
&'a mut self,
description: Option<String>,
) -> &'a mut Self
pub fn set_description<'a>( &'a mut self, description: Option<String>, ) -> &'a mut Self
Optional. Short description of the result
sourcepub fn get_thumbnail_url<'a>(&'a self) -> Option<&'a str>
pub fn get_thumbnail_url<'a>(&'a self) -> Option<&'a str>
Optional. Url of the thumbnail for the result
sourcepub fn set_thumbnail_url<'a>(
&'a mut self,
thumbnail_url: Option<String>,
) -> &'a mut Self
pub fn set_thumbnail_url<'a>( &'a mut self, thumbnail_url: Option<String>, ) -> &'a mut Self
Optional. Url of the thumbnail for the result
sourcepub fn get_thumbnail_width<'a>(&'a self) -> Option<i64>
pub fn get_thumbnail_width<'a>(&'a self) -> Option<i64>
Optional. Thumbnail width
sourcepub fn set_thumbnail_width<'a>(
&'a mut self,
thumbnail_width: Option<i64>,
) -> &'a mut Self
pub fn set_thumbnail_width<'a>( &'a mut self, thumbnail_width: Option<i64>, ) -> &'a mut Self
Optional. Thumbnail width
sourcepub fn get_thumbnail_height<'a>(&'a self) -> Option<i64>
pub fn get_thumbnail_height<'a>(&'a self) -> Option<i64>
Optional. Thumbnail height
sourcepub fn set_thumbnail_height<'a>(
&'a mut self,
thumbnail_height: Option<i64>,
) -> &'a mut Self
pub fn set_thumbnail_height<'a>( &'a mut self, thumbnail_height: Option<i64>, ) -> &'a mut Self
Optional. Thumbnail height
Trait Implementations§
source§impl Clone for InlineQueryResultArticle
impl Clone for InlineQueryResultArticle
source§fn clone(&self) -> InlineQueryResultArticle
fn clone(&self) -> InlineQueryResultArticle
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for InlineQueryResultArticle
impl Debug for InlineQueryResultArticle
source§impl Default for InlineQueryResultArticle
impl Default for InlineQueryResultArticle
source§fn default() -> InlineQueryResultArticle
fn default() -> InlineQueryResultArticle
source§impl<'de> Deserialize<'de> for InlineQueryResultArticle
impl<'de> Deserialize<'de> for InlineQueryResultArticle
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>,
source§impl From<BoxWrapper<Box<InlineQueryResultArticle>>> for InlineQueryResultArticle
impl From<BoxWrapper<Box<InlineQueryResultArticle>>> for InlineQueryResultArticle
source§fn from(t: BoxWrapper<Box<InlineQueryResultArticle>>) -> Self
fn from(t: BoxWrapper<Box<InlineQueryResultArticle>>) -> Self
source§impl From<BoxWrapper<Unbox<InlineQueryResultArticle>>> for InlineQueryResultArticle
impl From<BoxWrapper<Unbox<InlineQueryResultArticle>>> for InlineQueryResultArticle
source§fn from(t: BoxWrapper<Unbox<InlineQueryResultArticle>>) -> Self
fn from(t: BoxWrapper<Unbox<InlineQueryResultArticle>>) -> Self
source§impl From<NoSkipInlineQueryResultArticle> for InlineQueryResultArticle
impl From<NoSkipInlineQueryResultArticle> for InlineQueryResultArticle
source§fn from(t: NoSkipInlineQueryResultArticle) -> Self
fn from(t: NoSkipInlineQueryResultArticle) -> Self
source§impl Hash for InlineQueryResultArticle
impl Hash for InlineQueryResultArticle
source§impl Into<NoSkipInlineQueryResultArticle> for InlineQueryResultArticle
impl Into<NoSkipInlineQueryResultArticle> for InlineQueryResultArticle
source§fn into(self) -> NoSkipInlineQueryResultArticle
fn into(self) -> NoSkipInlineQueryResultArticle
source§impl Ord for InlineQueryResultArticle
impl Ord for InlineQueryResultArticle
source§fn cmp(&self, other: &InlineQueryResultArticle) -> Ordering
fn cmp(&self, other: &InlineQueryResultArticle) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
source§impl PartialEq for InlineQueryResultArticle
impl PartialEq for InlineQueryResultArticle
source§fn eq(&self, other: &InlineQueryResultArticle) -> bool
fn eq(&self, other: &InlineQueryResultArticle) -> bool
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for InlineQueryResultArticle
impl PartialOrd for InlineQueryResultArticle
source§fn partial_cmp(&self, other: &InlineQueryResultArticle) -> Option<Ordering>
fn partial_cmp(&self, other: &InlineQueryResultArticle) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
self
and other
) and is used by the <=
operator. Read moresource§impl Serialize for InlineQueryResultArticle
impl Serialize for InlineQueryResultArticle
impl Eq for InlineQueryResultArticle
impl StructuralPartialEq for InlineQueryResultArticle
Auto Trait Implementations§
impl Freeze for InlineQueryResultArticle
impl RefUnwindSafe for InlineQueryResultArticle
impl Send for InlineQueryResultArticle
impl Sync for InlineQueryResultArticle
impl Unpin for InlineQueryResultArticle
impl UnwindSafe for InlineQueryResultArticle
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.