pub trait SubCommandGroup: Sized {
// Required methods
fn create_option(
name: impl Into<String>,
description: impl Into<String>,
) -> CreateCommandOption;
fn from_value(value: &CommandDataOptionValue) -> Result<Self>;
}
Expand description
A sub-command group which can be nested inside of a Command
and contains
SubCommand
s.
This is a super-trait of SubCommand
, as a SubCommand
can be used
anywhere a SubCommandGroup
can.
Required Methods§
Sourcefn create_option(
name: impl Into<String>,
description: impl Into<String>,
) -> CreateCommandOption
fn create_option( name: impl Into<String>, description: impl Into<String>, ) -> CreateCommandOption
Create the command option.
Sourcefn from_value(value: &CommandDataOptionValue) -> Result<Self>
fn from_value(value: &CommandDataOptionValue) -> Result<Self>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.