Minestom/src/main/java/net/minestom/server/command/builder/CommandExecutor.java

19 lines
624 B
Java
Raw Normal View History

package net.minestom.server.command.builder;
import net.minestom.server.command.CommandSender;
2020-10-24 16:58:27 +02:00
import org.jetbrains.annotations.NotNull;
/**
* Callback executed once a syntax has been found for a {@link Command}.
*/
2020-10-11 18:35:32 +02:00
@FunctionalInterface
public interface CommandExecutor {
/**
2020-11-12 03:09:36 +01:00
* Executes the command callback once the syntax has been called (or the default executor).
*
2021-03-10 06:38:51 +01:00
* @param sender the sender of the command
* @param context the command context, used to retrieve the arguments and various other things
*/
2021-03-10 06:38:51 +01:00
void apply(@NotNull CommandSender sender, @NotNull CommandContext context);
}