Package tech.xigam.cch.command
Interface BaseCommand
- All Known Implementing Classes:
Alias,Command,DeployCommand,SubCommand
public interface BaseCommand
-
Method Summary
Modifier and TypeMethodDescriptiondefault net.dv8tion.jda.api.interactions.components.buttons.ButtoncreateButton(net.dv8tion.jda.api.interactions.components.buttons.ButtonStyle style, String reference, String text) Creates a button with proper handling for this command.default net.dv8tion.jda.api.interactions.components.buttons.ButtoncreateButton(net.dv8tion.jda.api.interactions.components.buttons.ButtonStyle style, String reference, String text, net.dv8tion.jda.api.entities.emoji.Emoji emoji) Creates a button with proper handling for this command.default net.dv8tion.jda.api.interactions.components.buttons.ButtoncreateButton(net.dv8tion.jda.api.interactions.components.buttons.ButtonStyle style, String reference, net.dv8tion.jda.api.entities.emoji.Emoji emoji) Creates a button with proper handling for this command.default net.dv8tion.jda.api.interactions.components.selections.SelectMenucreateSelectMenu(String reference, String placeHolder, MenuOption... options) Creates a select menu with proper handling for this command.default net.dv8tion.jda.api.interactions.components.selections.SelectMenucreateSelectMenu(String reference, MenuOption... options) Creates a select menu with proper handling for this command.voidexecute(Interaction interaction) getLabel()voidprepareForCallback(String cmdLabel, net.dv8tion.jda.api.events.interaction.component.ButtonInteractionEvent event, ComplexCommandHandler handler) voidprepareForCallback(String cmdLabel, net.dv8tion.jda.api.events.interaction.component.SelectMenuInteractionEvent event, ComplexCommandHandler handler) voidprepareForCompletion(net.dv8tion.jda.api.events.interaction.command.CommandAutoCompleteInteractionEvent event, ComplexCommandHandler handler) voidprepareForExecution(List<String> arguments, net.dv8tion.jda.api.entities.Message message, net.dv8tion.jda.api.entities.Member sender, net.dv8tion.jda.api.entities.MessageChannel channel, boolean skipArguments, ComplexCommandHandler handler) voidprepareForExecution(net.dv8tion.jda.api.events.interaction.command.SlashCommandInteractionEvent event, ComplexCommandHandler handler)
-
Method Details
-
getLabel
String getLabel() -
getDescription
String getDescription() -
execute
-
prepareForExecution
void prepareForExecution(List<String> arguments, net.dv8tion.jda.api.entities.Message message, net.dv8tion.jda.api.entities.Member sender, net.dv8tion.jda.api.entities.MessageChannel channel, boolean skipArguments, ComplexCommandHandler handler) -
prepareForExecution
void prepareForExecution(net.dv8tion.jda.api.events.interaction.command.SlashCommandInteractionEvent event, ComplexCommandHandler handler) -
prepareForCompletion
void prepareForCompletion(net.dv8tion.jda.api.events.interaction.command.CommandAutoCompleteInteractionEvent event, ComplexCommandHandler handler) -
prepareForCallback
void prepareForCallback(String cmdLabel, net.dv8tion.jda.api.events.interaction.component.ButtonInteractionEvent event, ComplexCommandHandler handler) -
prepareForCallback
void prepareForCallback(String cmdLabel, net.dv8tion.jda.api.events.interaction.component.SelectMenuInteractionEvent event, ComplexCommandHandler handler) -
createButton
default net.dv8tion.jda.api.interactions.components.buttons.Button createButton(net.dv8tion.jda.api.interactions.components.buttons.ButtonStyle style, String reference, String text) Creates a button with proper handling for this command.- Parameters:
style- The button style.reference- The reference to the button (or a URL).text- The text to display on the button.- Returns:
- The button.
-
createButton
default net.dv8tion.jda.api.interactions.components.buttons.Button createButton(net.dv8tion.jda.api.interactions.components.buttons.ButtonStyle style, String reference, net.dv8tion.jda.api.entities.emoji.Emoji emoji) Creates a button with proper handling for this command.- Parameters:
style- The button style.reference- The reference to the button (or a URL).emoji- The emoji to show on the button.- Returns:
- The button.
-
createButton
default net.dv8tion.jda.api.interactions.components.buttons.Button createButton(net.dv8tion.jda.api.interactions.components.buttons.ButtonStyle style, String reference, String text, net.dv8tion.jda.api.entities.emoji.Emoji emoji) Creates a button with proper handling for this command.- Parameters:
style- The button style.reference- The reference to the button (or a URL).text- The text to show to the right of the emoji.emoji- The emoji to show on the button.- Returns:
- The button.
-
createSelectMenu
default net.dv8tion.jda.api.interactions.components.selections.SelectMenu createSelectMenu(String reference, MenuOption... options) Creates a select menu with proper handling for this command.- Parameters:
reference- The reference to the select menu.options- The options to show in the select menu.- Returns:
- The select menu.
-
createSelectMenu
default net.dv8tion.jda.api.interactions.components.selections.SelectMenu createSelectMenu(String reference, String placeHolder, MenuOption... options) Creates a select menu with proper handling for this command.- Parameters:
reference- The reference to the select menu.placeHolder- The placeholder to display in the menu.options- The options to show in the select menu.- Returns:
- The select menu.
-