Rename Command#addConditionalSyntax

This commit is contained in:
themode 2021-03-27 18:28:10 +01:00
parent 156c6a31df
commit 27cfe9c92b
1 changed files with 6 additions and 6 deletions

View File

@ -130,9 +130,9 @@ public class Command {
* there can be multiple of them when optional arguments are used * there can be multiple of them when optional arguments are used
*/ */
@NotNull @NotNull
public Collection<CommandSyntax> addSyntax(@Nullable CommandCondition commandCondition, public Collection<CommandSyntax> addConditionalSyntax(@Nullable CommandCondition commandCondition,
@NotNull CommandExecutor executor, @NotNull CommandExecutor executor,
@NotNull Argument<?>... args) { @NotNull Argument<?>... args) {
// Check optional argument(s) // Check optional argument(s)
boolean hasOptional = false; boolean hasOptional = false;
{ {
@ -196,11 +196,11 @@ public class Command {
/** /**
* Adds a new syntax without condition. * Adds a new syntax without condition.
* *
* @see #addSyntax(CommandCondition, CommandExecutor, Argument[]) * @see #addConditionalSyntax(CommandCondition, CommandExecutor, Argument[])
*/ */
@NotNull @NotNull
public Collection<CommandSyntax> addSyntax(@NotNull CommandExecutor executor, @NotNull Argument<?>... args) { public Collection<CommandSyntax> addSyntax(@NotNull CommandExecutor executor, @NotNull Argument<?>... args) {
return addSyntax(null, executor, args); return addConditionalSyntax(null, executor, args);
} }
/** /**
@ -249,7 +249,7 @@ public class Command {
* Gets all the syntaxes of this command. * Gets all the syntaxes of this command.
* *
* @return a collection containing all this command syntaxes * @return a collection containing all this command syntaxes
* @see #addSyntax(CommandCondition, CommandExecutor, Argument[]) * @see #addSyntax(CommandExecutor, Argument[])
*/ */
@NotNull @NotNull
public Collection<CommandSyntax> getSyntaxes() { public Collection<CommandSyntax> getSyntaxes() {