#[non_exhaustive]pub struct CurrentUserGuild {
pub id: GuildId,
pub name: CompactString,
pub icon: Option<ImageHash>,
pub banner: Option<ImageHash>,
pub owner: bool,
pub permissions: Permissions,
pub features: Vec<Feature>,
pub approximate_member_count: Option<u32>,
pub approximate_presence_count: Option<u32>,
}Expand description
A guild of the current user, as returned by Get Current User Guilds.
discord.js counterpart: OAuth2Guild.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.id: GuildIdThe guild’s ID.
name: CompactStringThe guild’s name.
icon: Option<ImageHash>The icon hash.
The banner hash.
owner: boolWhether the current user owns the guild.
permissions: PermissionsThe current user’s permissions in the guild.
features: Vec<Feature>The guild’s features.
approximate_member_count: Option<u32>The approximate number of members (with with_counts).
approximate_presence_count: Option<u32>The approximate number of online members (with with_counts).
Trait Implementations§
Source§impl Clone for CurrentUserGuild
impl Clone for CurrentUserGuild
Source§impl Debug for CurrentUserGuild
impl Debug for CurrentUserGuild
Source§impl<'de> Deserialize<'de> for CurrentUserGuild
impl<'de> Deserialize<'de> for CurrentUserGuild
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
impl Eq for CurrentUserGuild
Source§impl Hash for CurrentUserGuild
impl Hash for CurrentUserGuild
Source§impl PartialEq for CurrentUserGuild
impl PartialEq for CurrentUserGuild
Source§impl Serialize for CurrentUserGuild
impl Serialize for CurrentUserGuild
impl StructuralPartialEq for CurrentUserGuild
Auto Trait Implementations§
impl Freeze for CurrentUserGuild
impl RefUnwindSafe for CurrentUserGuild
impl Send for CurrentUserGuild
impl Sync for CurrentUserGuild
impl Unpin for CurrentUserGuild
impl UnsafeUnpin for CurrentUserGuild
impl UnwindSafe for CurrentUserGuild
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