deprecated DelegatedBukkitCommand

This commit is contained in:
Samuel Pizette
2022-11-29 16:29:16 -05:00
parent 9af63907ef
commit f79f4a84c3

View File

@@ -1,5 +1,6 @@
package com.willfp.eco.core.command.impl;
import java.util.List;
import org.bukkit.command.Command;
import org.bukkit.command.CommandSender;
import org.bukkit.command.PluginIdentifiableCommand;
@@ -8,12 +9,13 @@ import org.bukkit.plugin.Plugin;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.util.List;
@Deprecated(forRemoval = true)
/**
* Delegates a bukkit command to an eco command (for registrations).
*/
public final class DelegatedBukkitCommand extends Command implements TabCompleter, PluginIdentifiableCommand {
public final class DelegatedBukkitCommand extends Command implements TabCompleter,
PluginIdentifiableCommand {
/**
* The delegate command.
*/
@@ -32,17 +34,17 @@ public final class DelegatedBukkitCommand extends Command implements TabComplete
@Override
public boolean execute(@NotNull final CommandSender commandSender,
@NotNull final String label,
@NotNull final String[] args) {
return delegate.onCommand(commandSender, this, label, args);
@NotNull final String label,
@NotNull final String[] args) {
return false;
}
@Override
public List<String> onTabComplete(@NotNull final CommandSender commandSender,
@NotNull final Command command,
@NotNull final String label,
@NotNull final String[] args) {
return delegate.onTabComplete(commandSender, command, label, args);
@NotNull final Command command,
@NotNull final String label,
@NotNull final String[] args) {
return List.of();
}
@NotNull