pub enum SubcommandCommandOption {
String(StringOption),
Integer(IntegerOption),
Boolean(BooleanOption),
User(UserOption),
Channel(ChannelOption),
Role(RoleOption),
Mentionable(MentionableOption),
Number(NumberOption),
Attachment(AttachmentOption),
}
Expand description
Subcommand options
Variants§
String(StringOption)
Integer(IntegerOption)
Boolean(BooleanOption)
User(UserOption)
Channel(ChannelOption)
Role(RoleOption)
Mentionable(MentionableOption)
Number(NumberOption)
Attachment(AttachmentOption)
Implementations§
Source§impl SubcommandCommandOption
impl SubcommandCommandOption
pub fn new_string_option( name: String, description: String, required: Option<bool>, choices: Option<Vec<ApplicationCommandOptionChoice<String>>>, min_length: Option<i32>, max_length: Option<i32>, autocomplete: Option<bool>, ) -> SubcommandCommandOption
pub fn new_integer_option( name: String, description: String, required: Option<bool>, choices: Option<Vec<ApplicationCommandOptionChoice<i64>>>, min_value: Option<i64>, max_value: Option<i64>, autocomplete: Option<bool>, ) -> SubcommandCommandOption
pub fn new_boolean_option( name: String, description: String, required: Option<bool>, ) -> SubcommandCommandOption
pub fn new_user_option( name: String, description: String, required: Option<bool>, ) -> SubcommandCommandOption
pub fn new_channel_option( name: String, description: String, required: Option<bool>, ) -> SubcommandCommandOption
pub fn new_role_option( name: String, description: String, required: Option<bool>, ) -> SubcommandCommandOption
pub fn new_mentionable_option( name: String, description: String, required: Option<bool>, ) -> SubcommandCommandOption
pub fn new_attachment_option( name: String, description: String, required: Option<bool>, ) -> SubcommandCommandOption
pub fn new_number_option( name: String, description: String, required: Option<bool>, choices: Option<Vec<ApplicationCommandOptionChoice<f64>>>, min_value: Option<f64>, max_value: Option<f64>, autocomplete: Option<bool>, ) -> SubcommandCommandOption
Trait Implementations§
Source§impl Debug for SubcommandCommandOption
impl Debug for SubcommandCommandOption
Source§impl<'de> Deserialize<'de> for SubcommandCommandOption
impl<'de> Deserialize<'de> for SubcommandCommandOption
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
Source§impl Serialize for SubcommandCommandOption
impl Serialize for SubcommandCommandOption
Auto Trait Implementations§
impl Freeze for SubcommandCommandOption
impl RefUnwindSafe for SubcommandCommandOption
impl Send for SubcommandCommandOption
impl Sync for SubcommandCommandOption
impl Unpin for SubcommandCommandOption
impl UnwindSafe for SubcommandCommandOption
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