Channel

Struct Channel 

Source
pub struct Channel {
Show 34 fields pub id: Snowflake, pub channel_type: ChannelType, pub guild_id: Option<String>, pub position: Option<i32>, pub permission_overwrites: Option<Vec<PermissionOverwrite>>, pub name: Option<String>, pub topic: Option<String>, pub nsfw: Option<bool>, pub last_message_id: Option<String>, pub bitrate: Option<i32>, pub user_limit: Option<i32>, pub rate_limit_per_user: Option<i32>, pub recipients: Option<Vec<User>>, pub icon: Option<String>, pub owner_id: Option<String>, pub application_id: Option<String>, pub parent_id: Option<String>, pub last_pin_timestamp: Option<String>, pub rtc_region: Option<String>, pub video_quality_mode: Option<i32>, pub message_count: Option<i32>, pub member_count: Option<i32>, pub thread_metadata: Option<ThreadMetadata>, pub member: Option<ThreadMember>, pub default_auto_archive_duration: Option<i32>, pub permissions: Option<String>, pub flags: Option<i32>, pub total_message_sent: Option<i32>, pub available_tags: Option<Vec<Tag>>, pub applied_tags: Option<Vec<String>>, pub default_reaction_emoji: Option<DefaultReaction>, pub default_thread_rate_limit_per_user: Option<i32>, pub default_sort_order: Option<i32>, pub default_forum_layout: Option<i32>,
}

Fields§

§id: Snowflake§channel_type: ChannelType§guild_id: Option<String>§position: Option<i32>§permission_overwrites: Option<Vec<PermissionOverwrite>>§name: Option<String>§topic: Option<String>§nsfw: Option<bool>§last_message_id: Option<String>§bitrate: Option<i32>§user_limit: Option<i32>§rate_limit_per_user: Option<i32>§recipients: Option<Vec<User>>§icon: Option<String>§owner_id: Option<String>§application_id: Option<String>§parent_id: Option<String>§last_pin_timestamp: Option<String>§rtc_region: Option<String>§video_quality_mode: Option<i32>§message_count: Option<i32>§member_count: Option<i32>§thread_metadata: Option<ThreadMetadata>§member: Option<ThreadMember>§default_auto_archive_duration: Option<i32>§permissions: Option<String>§flags: Option<i32>§total_message_sent: Option<i32>§available_tags: Option<Vec<Tag>>§applied_tags: Option<Vec<String>>§default_reaction_emoji: Option<DefaultReaction>§default_thread_rate_limit_per_user: Option<i32>§default_sort_order: Option<i32>§default_forum_layout: Option<i32>

Trait Implementations§

Source§

impl Clone for Channel

Source§

fn clone(&self) -> Channel

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Channel

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for Channel

Source§

fn default() -> Channel

Returns the “default value” for a type. Read more
Source§

impl<'de> Deserialize<'de> for Channel

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl PartialEq for Channel

Source§

fn eq(&self, other: &Channel) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Serialize for Channel

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl Eq for Channel

Source§

impl StructuralPartialEq for Channel

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,