![]() |
Bukkit
1.5.2-R1.0
|
Inheritance diagram for org.bukkit.command.defaults.HelpCommand:
Collaboration diagram for org.bukkit.command.defaults.HelpCommand:Public Member Functions | |
| HelpCommand () | |
| boolean | execute (CommandSender sender, String currentAlias, String[] args) |
| Executes the command, returning its success. | |
| boolean | matches (String input) |
| List< String > | tabComplete (CommandSender sender, String alias, String[] args) |
Public Member Functions inherited from org.bukkit.command.defaults.VanillaCommand | |
| boolean | matches (String input) |
Public Member Functions inherited from org.bukkit.command.Command | |
| List< String > | tabComplete (CommandSender sender, String[] args) |
| List< String > | tabComplete (CommandSender sender, String alias, String[] args) throws IllegalArgumentException |
| Executed on tab completion for this command, returning a list of options the player can tab through. | |
| String | getName () |
| Returns the name of this command. | |
| String | getPermission () |
| Gets the permission required by users to be able to perform this command. | |
| void | setPermission (String permission) |
| Sets the permission required by users to be able to perform this command. | |
| boolean | testPermission (CommandSender target) |
| Tests the given CommandSender to see if they can perform this command. | |
| boolean | testPermissionSilent (CommandSender target) |
| Tests the given CommandSender to see if they can perform this command. | |
| String | getLabel () |
| Returns the current lable for this command. | |
| boolean | setLabel (String name) |
| Sets the label of this command If the command is currently registered the label change will only take effect after its been reregistered e.g. | |
| boolean | register (CommandMap commandMap) |
| Registers this command to a CommandMap Once called it only allows changes the registered CommandMap. | |
| boolean | unregister (CommandMap commandMap) |
| Unregisters this command from the passed CommandMap applying any outstanding changes. | |
| boolean | isRegistered () |
| Returns the current registered state of this command. | |
| List< String > | getAliases () |
| Returns a list of active aliases of this command. | |
| String | getPermissionMessage () |
| Returns a message to be displayed on a failed permission check for this command. | |
| String | getDescription () |
| Gets a brief description of this command. | |
| String | getUsage () |
| Gets an example usage of this command. | |
| Command | setAliases (List< String > aliases) |
| Sets the list of aliases to request on registration for this command. | |
| Command | setDescription (String description) |
| Sets a brief description of this command. | |
| Command | setPermissionMessage (String permissionMessage) |
| Sets the message sent when a permission check fails. | |
| Command | setUsage (String usage) |
| Sets the example usage of this command. | |
| String | toString () |
Protected Member Functions | |
| HelpTopic | findPossibleMatches (String searchString) |
Protected Member Functions inherited from org.bukkit.command.defaults.VanillaCommand | |
| VanillaCommand (String name) | |
| VanillaCommand (String name, String description, String usageMessage, List< String > aliases) | |
| int | getInteger (CommandSender sender, String value, int min) |
Protected Member Functions inherited from org.bukkit.command.Command | |
| Command (String name) | |
| Command (String name, String description, String usageMessage, List< String > aliases) | |
Static Protected Member Functions | |
| static int | damerauLevenshteinDistance (String s1, String s2) |
| Computes the Dameraur-Levenshtein Distance between two strings. | |
Additional Inherited Members | |
Static Public Member Functions inherited from org.bukkit.command.defaults.VanillaCommand | |
| static double | getDouble (CommandSender sender, String input) |
| static double | getDouble (CommandSender sender, String input, double min, double max) |
Protected Attributes inherited from org.bukkit.command.Command | |
| String | description = "" |
| String | usageMessage |
Definition at line 26 of file HelpCommand.java.
| org.bukkit.command.defaults.HelpCommand.HelpCommand | ( | ) |
Definition at line 27 of file HelpCommand.java.
References org.bukkit.command.Command.description, org.bukkit.command.Command.setPermission(), and org.bukkit.command.Command.usageMessage.
|
staticprotected |
Computes the Dameraur-Levenshtein Distance between two strings.
Adapted from the algorithm at Wikipedia: Damerau–Levenshtein distance
| s1 | The first string being compared. |
| s2 | The second string being compared. |
Definition at line 178 of file HelpCommand.java.
Referenced by org.bukkit.command.defaults.HelpCommand.findPossibleMatches().
|
virtual |
Executes the command, returning its success.
| sender | Source object which is executing this command |
| commandLabel | The alias of the command used |
| args | All arguments passed to the command, split via ' ' |
Implements org.bukkit.command.Command.
Definition at line 35 of file HelpCommand.java.
References org.bukkit.help.HelpTopic.canSee(), org.bukkit.util.ChatPaginator.CLOSED_CHAT_PAGE_HEIGHT, org.bukkit.command.defaults.HelpCommand.findPossibleMatches(), org.bukkit.help.HelpTopic.getFullText(), org.bukkit.Server.getHelpMap(), org.bukkit.help.HelpMap.getHelpTopic(), org.bukkit.help.HelpTopic.getName(), org.bukkit.Bukkit.getServer(), org.bukkit.util.ChatPaginator.GUARANTEED_NO_WRAP_CHAT_PAGE_WIDTH, org.bukkit.util.ChatPaginator.paginate(), org.bukkit.ChatColor.RED, org.bukkit.command.CommandSender.sendMessage(), org.bukkit.command.Command.testPermission(), org.bukkit.util.ChatPaginator.UNBOUNDED_PAGE_HEIGHT, org.bukkit.util.ChatPaginator.UNBOUNDED_PAGE_WIDTH, org.bukkit.ChatColor.WHITE, and org.bukkit.ChatColor.YELLOW.
|
protected |
Definition at line 138 of file HelpCommand.java.
References org.bukkit.command.defaults.HelpCommand.damerauLevenshteinDistance(), org.bukkit.Server.getHelpMap(), org.bukkit.help.HelpMap.getHelpTopics(), org.bukkit.help.HelpTopic.getName(), org.bukkit.Bukkit.getServer(), and org.bukkit.help.HelpTopicComparator.helpTopicComparatorInstance().
Referenced by org.bukkit.command.defaults.HelpCommand.execute().
| boolean org.bukkit.command.defaults.HelpCommand.matches | ( | String | input | ) |
Definition at line 113 of file HelpCommand.java.
| List<String> org.bukkit.command.defaults.HelpCommand.tabComplete | ( | CommandSender | sender, |
| String | alias, | ||
| String[] | args | ||
| ) |
Definition at line 118 of file HelpCommand.java.
References org.bukkit.Server.getHelpMap(), org.bukkit.help.HelpMap.getHelpTopics(), and org.bukkit.Bukkit.getServer().