Skip to content

Commit

Permalink
Add helper to get root index help topic (#415)
Browse files Browse the repository at this point in the history
  • Loading branch information
jpenilla authored Dec 11, 2022
1 parent ae0150f commit a53b321
Showing 1 changed file with 13 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,19 @@ public final class CommandHelpHandler<C> {
return this.queryHelp(null, query);
}

/**
* Query a root index help topic. This is the topic returned when querying {@link #queryHelp(Object, String)} with
* an empty string, or when there are no results.
*
* @param recipient The recipient of this help query to check permissions against (if Non-Null)
* @return index help topic
* @since 1.8.0
*/
@API(status = API.Status.STABLE, since = "1.8.0")
public @NonNull IndexHelpTopic<C> queryRootIndex(final @Nullable C recipient) {
return (IndexHelpTopic<C>) this.queryHelp(recipient, "");
}

/**
* Query for help
*
Expand Down

0 comments on commit a53b321

Please sign in to comment.