#1338 Implement ''/authme messages help' to generate a fully complete help text file (#1349)

This commit is contained in:
ljacqu
2017-10-09 07:19:38 +02:00
committed by GitHub
parent 5be3f8facc
commit 7afda20288
8 changed files with 187 additions and 17 deletions
@@ -19,7 +19,7 @@ public enum HelpSection {
CHILDREN("children");
private static final String PREFIX = "section.";
private final String key;
/**
@@ -28,11 +28,17 @@ public enum HelpSection {
* @param key the message key
*/
HelpSection(String key) {
this.key = "section." + key;
this.key = PREFIX + key;
}
/** @return the message key */
public String getKey() {
return key;
}
/** @return the key without the common prefix */
public String getEntryKey() {
// Note ljacqu 20171008: #getKey is called more often than this method, so we optimize for the former method
return key.substring(PREFIX.length());
}
}