public interface HelpMap
The HelpMap tracks all help topics registered in a Bukkit server. When the server starts up or is reloaded, help is processed and topics are added in the following order:
- General topics are loaded from the help.yml
- Plugins load and optionally call
- Registered plugin commands are processed by
HelpTopicFactoryobjects to create topics
- Topic contents are amended as directed in help.yml
Method SummaryModifier and TypeMethodDescription
HelpTopic topic)(Adds a topic to the server's help index.
()Clears out the contents of the help index.
String topicName)(Returns a help topic for a given topic name.
()Returns a collection of all the registered help topics.
()Gets the list of plugins the server administrator has chosen to exclude from the help index.
HelpTopicFactoryobject with given command base class.
getHelpTopicReturns a help topic for a given topic name.
topicName- The help topic name to look up.
HelpTopicobject matching the topic name or null if none can be found.
getHelpTopicsReturns a collection of all the registered help topics.
- All the registered help topics.
addTopicAdds a topic to the server's help index.
topic- The new help topic to add.
clearvoid clear()Clears out the contents of the help index. Normally called during server reload.
registerHelpTopicFactoryvoid registerHelpTopicFactory(@NotNull Class<?> commandClass, @NotNull HelpTopicFactory<?> factory)Associates a
HelpTopicFactoryobject with given command base class. Plugins typically call this method during
onLoad(). Once registered, the custom HelpTopicFactory will be used to create a custom
HelpTopicfor all commands deriving from the
commandClassbase class, or all commands deriving from
PluginCommandwho's executor derives from
commandClass- The class for which the custom HelpTopicFactory applies. Must derive from either
HelpTopicFactoryimplementation to associate with the
IllegalArgumentException- Thrown if
commandClassdoes not derive from a legal base class.
getIgnoredPluginsGets the list of plugins the server administrator has chosen to exclude from the help index. Plugin authors who choose to directly extend
PluginCommandwill need to check this collection in their
HelpTopicFactoryimplementations to ensure they meet the server administrator's expectations.
- A list of plugins that should be excluded from the help index.