Struct carapax::types::InlineQueryResultMpeg4Gif
source · pub struct InlineQueryResultMpeg4Gif { /* private fields */ }
Expand description
Represents a link to a video animation (H.264/MPEG-4 AVC video without sound).
By default, this animated MPEG-4 file will be sent by the user with optional caption.
Alternatively, you can use Self::with_input_message_content
to send a message with the specified content instead of the animation.
Implementations§
source§impl InlineQueryResultMpeg4Gif
impl InlineQueryResultMpeg4Gif
sourcepub fn new<A, B, C>(
id: A,
mpeg4_url: B,
thumbnail_url: C
) -> InlineQueryResultMpeg4Gif
pub fn new<A, B, C>( id: A, mpeg4_url: B, thumbnail_url: C ) -> InlineQueryResultMpeg4Gif
Creates a new InlineQueryResultMpeg4Gif
.
§Arguments
id
- Unique identifier for the result; 1-64 bytes.mpeg4_url
- A valid URL for the MP4 file; file size must not exceed 1MB.thumbnail_url
- URL of the static thumbnail (jpeg or gif) for the result.
sourcepub fn with_input_message_content<T>(
self,
value: T
) -> InlineQueryResultMpeg4Gifwhere
T: Into<InputMessageContent>,
pub fn with_input_message_content<T>(
self,
value: T
) -> InlineQueryResultMpeg4Gifwhere
T: Into<InputMessageContent>,
Sets a new input message content.
§Arguments
value
- Content of the message to be sent instead of the video animation.
sourcepub fn with_mpeg4_duration(self, value: i64) -> InlineQueryResultMpeg4Gif
pub fn with_mpeg4_duration(self, value: i64) -> InlineQueryResultMpeg4Gif
sourcepub fn with_mpeg4_height(self, value: i64) -> InlineQueryResultMpeg4Gif
pub fn with_mpeg4_height(self, value: i64) -> InlineQueryResultMpeg4Gif
sourcepub fn with_mpeg4_width(self, value: i64) -> InlineQueryResultMpeg4Gif
pub fn with_mpeg4_width(self, value: i64) -> InlineQueryResultMpeg4Gif
sourcepub fn with_reply_markup<T>(self, value: T) -> InlineQueryResultMpeg4Gifwhere
T: Into<InlineKeyboardMarkup>,
pub fn with_reply_markup<T>(self, value: T) -> InlineQueryResultMpeg4Gifwhere
T: Into<InlineKeyboardMarkup>,
sourcepub fn with_thumbnail_mime_type<T>(self, value: T) -> InlineQueryResultMpeg4Gif
pub fn with_thumbnail_mime_type<T>(self, value: T) -> InlineQueryResultMpeg4Gif
Sets a new thumbnail MIME type.
§Arguments
value
- MIME type of the thumbnail; default - “image/jpeg”.
Must be one of “image/jpeg”, “image/gif”, or “video/mp4”.
sourcepub fn with_title<T>(self, value: T) -> InlineQueryResultMpeg4Gif
pub fn with_title<T>(self, value: T) -> InlineQueryResultMpeg4Gif
Trait Implementations§
source§impl Clone for InlineQueryResultMpeg4Gif
impl Clone for InlineQueryResultMpeg4Gif
source§fn clone(&self) -> InlineQueryResultMpeg4Gif
fn clone(&self) -> InlineQueryResultMpeg4Gif
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 InlineQueryResultMpeg4Gif
impl Debug for InlineQueryResultMpeg4Gif
source§impl<'de> Deserialize<'de> for InlineQueryResultMpeg4Gif
impl<'de> Deserialize<'de> for InlineQueryResultMpeg4Gif
source§fn deserialize<__D>(
__deserializer: __D
) -> Result<InlineQueryResultMpeg4Gif, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D
) -> Result<InlineQueryResultMpeg4Gif, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl From<InlineQueryResultMpeg4Gif> for InlineQueryResult
impl From<InlineQueryResultMpeg4Gif> for InlineQueryResult
source§fn from(original: InlineQueryResultMpeg4Gif) -> InlineQueryResult
fn from(original: InlineQueryResultMpeg4Gif) -> InlineQueryResult
Converts to this type from the input type.
source§impl PartialEq for InlineQueryResultMpeg4Gif
impl PartialEq for InlineQueryResultMpeg4Gif
source§fn eq(&self, other: &InlineQueryResultMpeg4Gif) -> bool
fn eq(&self, other: &InlineQueryResultMpeg4Gif) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for InlineQueryResultMpeg4Gif
impl Serialize for InlineQueryResultMpeg4Gif
source§fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
source§impl TryFrom<RawInlineQueryResult> for InlineQueryResultMpeg4Gif
impl TryFrom<RawInlineQueryResult> for InlineQueryResultMpeg4Gif
source§fn try_from(
value: RawInlineQueryResult
) -> Result<InlineQueryResultMpeg4Gif, <InlineQueryResultMpeg4Gif as TryFrom<RawInlineQueryResult>>::Error>
fn try_from( value: RawInlineQueryResult ) -> Result<InlineQueryResultMpeg4Gif, <InlineQueryResultMpeg4Gif as TryFrom<RawInlineQueryResult>>::Error>
Performs the conversion.
impl StructuralPartialEq for InlineQueryResultMpeg4Gif
Auto Trait Implementations§
impl Freeze for InlineQueryResultMpeg4Gif
impl RefUnwindSafe for InlineQueryResultMpeg4Gif
impl Send for InlineQueryResultMpeg4Gif
impl Sync for InlineQueryResultMpeg4Gif
impl Unpin for InlineQueryResultMpeg4Gif
impl UnwindSafe for InlineQueryResultMpeg4Gif
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
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>
Converts
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>
Converts
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