pub struct ChatPermissions {Show 16 fields
pub can_send_messages: Option<bool>,
pub can_send_audios: Option<bool>,
pub can_send_documents: Option<bool>,
pub can_send_photos: Option<bool>,
pub can_send_videos: Option<bool>,
pub can_send_video_notes: Option<bool>,
pub can_send_voice_notes: Option<bool>,
pub can_send_polls: Option<bool>,
pub can_send_other_messages: Option<bool>,
pub can_add_web_page_previews: Option<bool>,
pub can_change_info: Option<bool>,
pub can_invite_users: Option<bool>,
pub can_pin_messages: Option<bool>,
pub can_manage_topics: Option<bool>,
pub can_edit_tag: Option<bool>,
pub can_react_to_messages: Option<bool>,
}Expand description
Defines chat permissions for regular members.
Fields§
§can_send_messages: Option<bool>Allows sending text messages.
can_send_audios: Option<bool>Allows sending audio files.
can_send_documents: Option<bool>Allows sending documents.
can_send_photos: Option<bool>Allows sending photos.
can_send_videos: Option<bool>Allows sending videos.
can_send_video_notes: Option<bool>Allows sending video notes.
can_send_voice_notes: Option<bool>Allows sending voice notes.
can_send_polls: Option<bool>Allows sending polls.
can_send_other_messages: Option<bool>Allows sending other types of messages (stickers, GIFs, games, etc.).
can_add_web_page_previews: Option<bool>Allows adding web page previews to messages.
can_change_info: Option<bool>Allows changing the chat title, photo, and other settings.
can_invite_users: Option<bool>Allows inviting new users to the chat.
can_pin_messages: Option<bool>Allows pinning messages.
can_manage_topics: Option<bool>Allows managing forum topics (supergroups only).
can_edit_tag: Option<bool>Allows editing the chat tag (supergroups only).
can_react_to_messages: Option<bool>Allows reacting to messages.
If omitted, defaults to the value of can_send_messages.
Trait Implementations§
Source§impl Clone for ChatPermissions
impl Clone for ChatPermissions
Source§fn clone(&self) -> ChatPermissions
fn clone(&self) -> ChatPermissions
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 ChatPermissions
impl Debug for ChatPermissions
Source§impl Default for ChatPermissions
impl Default for ChatPermissions
Source§fn default() -> ChatPermissions
fn default() -> ChatPermissions
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for ChatPermissions
impl<'de> Deserialize<'de> for ChatPermissions
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
Auto Trait Implementations§
impl Freeze for ChatPermissions
impl RefUnwindSafe for ChatPermissions
impl Send for ChatPermissions
impl Sync for ChatPermissions
impl Unpin for ChatPermissions
impl UnsafeUnpin for ChatPermissions
impl UnwindSafe for ChatPermissions
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