Class BrigadierHelper
java.lang.Object
com.soulfiremc.server.command.brigadier.BrigadierHelper
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfacestatic final recordstatic final recordstatic interface -
Method Summary
Modifier and TypeMethodDescriptionstatic <T> com.mojang.brigadier.builder.RequiredArgumentBuilder<CommandSourceStack, T> static intforEveryBot(com.mojang.brigadier.context.CommandContext<CommandSourceStack> context, BrigadierHelper.CommandFunction<BotConnection> consumer) static intforEveryInstance(com.mojang.brigadier.context.CommandContext<CommandSourceStack> context, BrigadierHelper.CommandFunction<InstanceManager> consumer) static intforEveryInstanceEnsureHasBots(com.mojang.brigadier.context.CommandContext<CommandSourceStack> context, BrigadierHelper.CommandFunction<InstanceManager> consumer) static BrigadierHelper.CommandHelpInfo[]getAllUsage(com.mojang.brigadier.CommandDispatcher<CommandSourceStack> dispatcher, com.mojang.brigadier.tree.CommandNode<CommandSourceStack> node, CommandSourceStack source) static com.mojang.brigadier.Command<CommandSourceStack> help(String help, com.mojang.brigadier.Command<CommandSourceStack> command) static com.mojang.brigadier.RedirectModifier<CommandSourceStack> helpRedirect(String help, com.mojang.brigadier.RedirectModifier<CommandSourceStack> redirect) static com.mojang.brigadier.RedirectModifier<CommandSourceStack> helpSingleRedirect(String help, com.mojang.brigadier.SingleRedirectModifier<CommandSourceStack> redirect) static com.mojang.brigadier.builder.LiteralArgumentBuilder<CommandSourceStack> static com.mojang.brigadier.Command<CommandSourceStack> privateCommand(com.mojang.brigadier.Command<CommandSourceStack> command) static @Nullable net.kyori.adventure.text.ComponenttoComponent(@Nullable com.mojang.brigadier.Message message)
-
Method Details
-
literal
public static com.mojang.brigadier.builder.LiteralArgumentBuilder<CommandSourceStack> literal(String name) -
argument
public static <T> com.mojang.brigadier.builder.RequiredArgumentBuilder<CommandSourceStack, T> argument(String name, com.mojang.brigadier.arguments.ArgumentType<T> type) -
help
public static com.mojang.brigadier.Command<CommandSourceStack> help(String help, com.mojang.brigadier.Command<CommandSourceStack> command) -
helpRedirect
public static com.mojang.brigadier.RedirectModifier<CommandSourceStack> helpRedirect(String help, com.mojang.brigadier.RedirectModifier<CommandSourceStack> redirect) -
helpSingleRedirect
public static com.mojang.brigadier.RedirectModifier<CommandSourceStack> helpSingleRedirect(String help, com.mojang.brigadier.SingleRedirectModifier<CommandSourceStack> redirect) -
privateCommand
public static com.mojang.brigadier.Command<CommandSourceStack> privateCommand(com.mojang.brigadier.Command<CommandSourceStack> command) -
getAllUsage
public static BrigadierHelper.CommandHelpInfo[] getAllUsage(com.mojang.brigadier.CommandDispatcher<CommandSourceStack> dispatcher, com.mojang.brigadier.tree.CommandNode<CommandSourceStack> node, CommandSourceStack source) -
forEveryInstance
public static int forEveryInstance(com.mojang.brigadier.context.CommandContext<CommandSourceStack> context, BrigadierHelper.CommandFunction<InstanceManager> consumer) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
forEveryInstanceEnsureHasBots
public static int forEveryInstanceEnsureHasBots(com.mojang.brigadier.context.CommandContext<CommandSourceStack> context, BrigadierHelper.CommandFunction<InstanceManager> consumer) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
forEveryBot
public static int forEveryBot(com.mojang.brigadier.context.CommandContext<CommandSourceStack> context, BrigadierHelper.CommandFunction<BotConnection> consumer) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
toComponent
public static @Nullable net.kyori.adventure.text.Component toComponent(@Nullable com.mojang.brigadier.Message message)
-