Struct frankenstein::objects::Chat
source · [−]pub struct Chat {Show 20 fields
pub id: i64,
pub type_field: ChatType,
pub title: Option<String>,
pub username: Option<String>,
pub first_name: Option<String>,
pub last_name: Option<String>,
pub photo: Option<ChatPhoto>,
pub bio: Option<String>,
pub has_private_forwards: Option<bool>,
pub description: Option<String>,
pub invite_link: Option<String>,
pub pinned_message: Option<Box<Message>>,
pub permissions: Option<ChatPermissions>,
pub slow_mode_delay: Option<u16>,
pub message_auto_delete_time: Option<u32>,
pub has_protected_content: Option<bool>,
pub sticker_set_name: Option<String>,
pub can_set_sticker_set: Option<bool>,
pub linked_chat_id: Option<i64>,
pub location: Option<ChatLocation>,
}
Fields
id: i64
type_field: ChatType
title: Option<String>
username: Option<String>
first_name: Option<String>
last_name: Option<String>
photo: Option<ChatPhoto>
bio: Option<String>
has_private_forwards: Option<bool>
description: Option<String>
invite_link: Option<String>
pinned_message: Option<Box<Message>>
permissions: Option<ChatPermissions>
slow_mode_delay: Option<u16>
message_auto_delete_time: Option<u32>
has_protected_content: Option<bool>
sticker_set_name: Option<String>
can_set_sticker_set: Option<bool>
linked_chat_id: Option<i64>
location: Option<ChatLocation>
Implementations
sourceimpl Chat
impl Chat
sourcepub fn builder(
) -> ChatBuilder<((), (), (), (), (), (), (), (), (), (), (), (), (), (), (), (), (), (), (), ())>
pub fn builder(
) -> ChatBuilder<((), (), (), (), (), (), (), (), (), (), (), (), (), (), (), (), (), (), (), ())>
Create a builder for building Chat
.
On the builder, call .id(...)
, .type_field(...)
, .title(...)
(optional), .username(...)
(optional), .first_name(...)
(optional), .last_name(...)
(optional), .photo(...)
(optional), .bio(...)
(optional), .has_private_forwards(...)
(optional), .description(...)
(optional), .invite_link(...)
(optional), .pinned_message(...)
(optional), .permissions(...)
(optional), .slow_mode_delay(...)
(optional), .message_auto_delete_time(...)
(optional), .has_protected_content(...)
(optional), .sticker_set_name(...)
(optional), .can_set_sticker_set(...)
(optional), .linked_chat_id(...)
(optional), .location(...)
(optional) to set the values of the fields.
Finally, call .build()
to create the instance of Chat
.
Trait Implementations
sourceimpl<'de> Deserialize<'de> for Chat
impl<'de> Deserialize<'de> for Chat
sourcefn 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
impl StructuralPartialEq for Chat
Auto Trait Implementations
impl RefUnwindSafe for Chat
impl Send for Chat
impl Sync for Chat
impl Unpin for Chat
impl UnwindSafe for Chat
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more