Class CommandUtil
java.lang.Object
com.sk89q.worldedit.internal.command.CommandUtil
- 
Nested Class SummaryNested ClassesModifier and TypeClassDescriptionstatic interfacestatic interface
- 
Method SummaryModifier and TypeMethodDescriptionstatic Comparator<org.enginehub.piston.Command> static voidcheckCommandArgument(boolean condition, com.sk89q.worldedit.util.formatting.text.Component message) Requireconditionto betrue, otherwise throw aCommandExceptionwith the given message.static voidcheckCommandArgument(boolean condition, String message) Requireconditionto betrue, otherwise throw aCommandExceptionwith the given message.static com.sk89q.worldedit.util.formatting.text.ComponentcreateNewCommandReplacementText(String suggestedCommand) static org.enginehub.piston.Commanddeprecate(org.enginehub.piston.Command command, String reason, CommandUtil.ReplacementMessageGenerator replacementMessageGenerator) static Optional<com.sk89q.worldedit.util.formatting.text.Component> deprecationWarning(org.enginehub.piston.Command command) fixSuggestions(String arguments, List<Substring> suggestions) Fixsuggestionsto replace the last space-separated word inarguments.static Optional<com.sk89q.worldedit.util.formatting.text.Component> footerWithoutDeprecation(org.enginehub.piston.Command command) getSubCommands(org.enginehub.piston.Command currentCommand) static booleanisDeprecated(org.enginehub.piston.Command command) static <T> TrequireIV(org.enginehub.piston.inject.Key<T> type, String name, org.enginehub.piston.inject.InjectedValueAccess injectedValueAccess) 
- 
Method Details- 
createNewCommandReplacementTextpublic static com.sk89q.worldedit.util.formatting.text.Component createNewCommandReplacementText(String suggestedCommand) 
- 
deprecatepublic static org.enginehub.piston.Command deprecate(org.enginehub.piston.Command command, String reason, CommandUtil.ReplacementMessageGenerator replacementMessageGenerator) 
- 
deprecationWarningpublic static Optional<com.sk89q.worldedit.util.formatting.text.Component> deprecationWarning(org.enginehub.piston.Command command) 
- 
isDeprecatedpublic static boolean isDeprecated(org.enginehub.piston.Command command) 
- 
getSubCommands
- 
byCleanName
- 
fixSuggestionsFixsuggestionsto replace the last space-separated word inarguments.
- 
checkCommandArgumentRequireconditionto betrue, otherwise throw aCommandExceptionwith the given message.- Parameters:
- condition- the condition to check
- message- the message for failure
 
- 
checkCommandArgumentpublic static void checkCommandArgument(boolean condition, com.sk89q.worldedit.util.formatting.text.Component message) Requireconditionto betrue, otherwise throw aCommandExceptionwith the given message.- Parameters:
- condition- the condition to check
- message- the message for failure
 
- 
requireIVpublic static <T> T requireIV(org.enginehub.piston.inject.Key<T> type, String name, org.enginehub.piston.inject.InjectedValueAccess injectedValueAccess) 
 
-