Struct twilight_cache_inmemory::model::CachedGuild
source · pub struct CachedGuild { /* private fields */ }Expand description
Represents a cached Guild.
Implementations§
source§impl CachedGuild
impl CachedGuild
sourcepub const fn afk_channel_id(&self) -> Option<Id<ChannelMarker>>
pub const fn afk_channel_id(&self) -> Option<Id<ChannelMarker>>
ID of the AFK channel.
sourcepub const fn afk_timeout(&self) -> AfkTimeout
pub const fn afk_timeout(&self) -> AfkTimeout
AFK timeout in seconds.
sourcepub const fn application_id(&self) -> Option<Id<ApplicationMarker>>
pub const fn application_id(&self) -> Option<Id<ApplicationMarker>>
For bot created guilds, the ID of the creating application.
Banner hash.
sourcepub const fn default_message_notifications(
&self
) -> DefaultMessageNotificationLevel
pub const fn default_message_notifications(
&self
) -> DefaultMessageNotificationLevel
Default message notification level.
sourcepub fn description(&self) -> Option<&str>
pub fn description(&self) -> Option<&str>
For Community guilds, the description.
sourcepub const fn discovery_splash(&self) -> Option<&ImageHash>
pub const fn discovery_splash(&self) -> Option<&ImageHash>
For discoverable guilds, the discovery splash hash.
sourcepub const fn explicit_content_filter(&self) -> ExplicitContentFilter
pub const fn explicit_content_filter(&self) -> ExplicitContentFilter
Explicit content filter level.
sourcepub fn features(&self) -> Features<'_>
pub fn features(&self) -> Features<'_>
Enabled guild features.
sourcepub const fn id(&self) -> Id<GuildMarker>
pub const fn id(&self) -> Id<GuildMarker>
ID of the guild.
sourcepub const fn max_members(&self) -> Option<u64>
pub const fn max_members(&self) -> Option<u64>
Maximum members.
sourcepub const fn max_presences(&self) -> Option<u64>
pub const fn max_presences(&self) -> Option<u64>
Maximum presences.
sourcepub const fn max_video_channel_users(&self) -> Option<u64>
pub const fn max_video_channel_users(&self) -> Option<u64>
Maximum number of users in a video channel.
sourcepub const fn member_count(&self) -> Option<u64>
pub const fn member_count(&self) -> Option<u64>
Total number of members in the guild.
sourcepub const fn nsfw_level(&self) -> NSFWLevel
pub const fn nsfw_level(&self) -> NSFWLevel
NSFW level.
sourcepub const fn owner_id(&self) -> Id<UserMarker>
pub const fn owner_id(&self) -> Id<UserMarker>
ID of the guild’s owner.
sourcepub const fn permissions(&self) -> Option<Permissions>
pub const fn permissions(&self) -> Option<Permissions>
Total permissions for the current user in the guild, excluding overwrites.
sourcepub fn preferred_locale(&self) -> &str
pub fn preferred_locale(&self) -> &str
Preferred locale for Community guilds.
Used in server discovery and notices from Discord. Defaults to “en-US”.
Whether the premium progress bar is enabled.
Number of boosts this guild currently has.
Server boost level.
sourcepub const fn public_updates_channel_id(&self) -> Option<Id<ChannelMarker>>
pub const fn public_updates_channel_id(&self) -> Option<Id<ChannelMarker>>
ID of the where moderators of Community guilds receive notices from Discord.
sourcepub const fn rules_channel_id(&self) -> Option<Id<ChannelMarker>>
pub const fn rules_channel_id(&self) -> Option<Id<ChannelMarker>>
For Community guilds, the ID of the rules channel.
sourcepub const fn system_channel_id(&self) -> Option<Id<ChannelMarker>>
pub const fn system_channel_id(&self) -> Option<Id<ChannelMarker>>
ID of the channel where notices are posted.
Example notices include welcome messages and boost events.
sourcepub const fn system_channel_flags(&self) -> SystemChannelFlags
pub const fn system_channel_flags(&self) -> SystemChannelFlags
System channel flags.
Whether the guild is unavailable due to an outage.
sourcepub fn vanity_url_code(&self) -> Option<&str>
pub fn vanity_url_code(&self) -> Option<&str>
Vanity URL code.
sourcepub const fn verification_level(&self) -> VerificationLevel
pub const fn verification_level(&self) -> VerificationLevel
Required verification level.
sourcepub const fn widget_channel_id(&self) -> Option<Id<ChannelMarker>>
pub const fn widget_channel_id(&self) -> Option<Id<ChannelMarker>>
ID of the channel that a widget generates an invite to.
sourcepub const fn widget_enabled(&self) -> Option<bool>
pub const fn widget_enabled(&self) -> Option<bool>
Whether the widget is enabled.
Trait Implementations§
source§impl Clone for CachedGuild
impl Clone for CachedGuild
source§fn clone(&self) -> CachedGuild
fn clone(&self) -> CachedGuild
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moresource§impl Debug for CachedGuild
impl Debug for CachedGuild
source§impl PartialEq<CachedGuild> for CachedGuild
impl PartialEq<CachedGuild> for CachedGuild
source§fn eq(&self, other: &CachedGuild) -> bool
fn eq(&self, other: &CachedGuild) -> bool
self and other values to be equal, and is used
by ==.