Enum twilight_model::application::interaction::Interaction
source · [−]#[non_exhaustive]
pub enum Interaction {
Ping(Box<Ping>),
ApplicationCommand(Box<ApplicationCommand>),
ApplicationCommandAutocomplete(Box<ApplicationCommand>),
MessageComponent(Box<MessageComponentInteraction>),
}Expand description
Payload received when a user executes an interaction.
Each variant corresponds to InteractionType in the discord docs. Refer to
the discord docs for more information.
Variants (Non-exhaustive)
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Ping(Box<Ping>)
Ping variant.
ApplicationCommand(Box<ApplicationCommand>)
Application command variant.
ApplicationCommandAutocomplete(Box<ApplicationCommand>)
Application command autocomplete variant.
MessageComponent(Box<MessageComponentInteraction>)
Message component variant.
Implementations
Return the ID of the inner interaction.
Trait Implementations
Deserialize this value from the given Serde deserializer. Read more
This method tests for self and other values to be equal, and is used
by ==. Read more
This method tests for !=.
Auto Trait Implementations
impl RefUnwindSafe for Interaction
impl Send for Interaction
impl Sync for Interaction
impl Unpin for Interaction
impl UnwindSafe for Interaction
Blanket Implementations
Mutably borrows from an owned value. Read more
Attaches the provided Subscriber to this type, returning a
WithDispatch wrapper. Read more
Attaches the current default Subscriber to this type, returning a
WithDispatch wrapper. Read more