001 package org.bukkit.command;
002
003 import java.util.List;
004
005 /**
006 * Represents a class which can suggest tab completions for commands.
007 */
008 public interface TabCompleter {
009
010 /**
011 * Requests a list of possible completions for a command argument.
012 *
013 * @param sender Source of the command
014 * @param command Command which was executed
015 * @param alias The alias used
016 * @param args The arguments passed to the command, including final
017 * partial argument to be completed and command label
018 * @return A List of possible completions for the final argument, or null
019 * to default to the command executor
020 */
021 public List<String> onTabComplete(CommandSender sender, Command command, String alias, String[] args);
022 }