pub struct DiscordConfig {
pub enabled: bool,
pub token: String,
pub application_id: String,
pub interaction_public_key: Option<String>,
pub api_base_url: Option<String>,
pub attachment_download_dir: Option<String>,
pub rate_limit_requests_per_second: u32,
pub allowed_guilds: Vec<String>,
pub allowed_channels: Vec<String>,
pub dm_enabled: bool,
}Expand description
Discord bot configuration.
Fields§
§enabled: bool§token: String§application_id: String§interaction_public_key: Option<String>§api_base_url: Option<String>§attachment_download_dir: Option<String>§rate_limit_requests_per_second: u32§allowed_guilds: Vec<String>§allowed_channels: Vec<String>§dm_enabled: boolTrait Implementations§
Source§impl Clone for DiscordConfig
impl Clone for DiscordConfig
Source§fn clone(&self) -> DiscordConfig
fn clone(&self) -> DiscordConfig
Returns a duplicate of the value. Read more
1.0.0 · 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 DiscordConfig
impl Debug for DiscordConfig
Source§impl<'de> Deserialize<'de> for DiscordConfig
impl<'de> Deserialize<'de> for DiscordConfig
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 DiscordConfig
impl RefUnwindSafe for DiscordConfig
impl Send for DiscordConfig
impl Sync for DiscordConfig
impl Unpin for DiscordConfig
impl UnsafeUnpin for DiscordConfig
impl UnwindSafe for DiscordConfig
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