From e1069d367d116198cb2dfefc7c4de2e78ced181e Mon Sep 17 00:00:00 2001 From: Robert Field Date: Tue, 19 Dec 2017 11:37:00 -0800 Subject: [PATCH] 8179858: jshell tool: sync nomenclature from reference to online /help Reviewed-by: dlsmith, jjg --- .../jdk/internal/jshell/tool/JShellTool.java | 5 +- .../jshell/tool/resources/l10n.properties | 365 ++++++++++-------- .../jdk/jshell/CommandCompletionTest.java | 4 +- test/langtools/jdk/jshell/EditorTestBase.java | 2 +- test/langtools/jdk/jshell/ToolBasicTest.java | 10 +- test/langtools/jdk/jshell/ToolSimpleTest.java | 2 +- 6 files changed, 214 insertions(+), 174 deletions(-) diff --git a/src/jdk.jshell/share/classes/jdk/internal/jshell/tool/JShellTool.java b/src/jdk.jshell/share/classes/jdk/internal/jshell/tool/JShellTool.java index 79a0a1f71f8..8fc94b1b47b 100644 --- a/src/jdk.jshell/share/classes/jdk/internal/jshell/tool/JShellTool.java +++ b/src/jdk.jshell/share/classes/jdk/internal/jshell/tool/JShellTool.java @@ -1817,7 +1817,7 @@ public class JShellTool implements MessageHandler { // Documentation pseudo-commands registerCommand(new Command("/", - "help.id", + "help.slashID", arg -> cmdHelp("rerun"), EMPTY_COMPLETION_PROVIDER, CommandKind.HELP_ONLY)); @@ -1829,6 +1829,9 @@ public class JShellTool implements MessageHandler { registerCommand(new Command("intro", "help.intro", CommandKind.HELP_SUBJECT)); + registerCommand(new Command("id", + "help.id", + CommandKind.HELP_SUBJECT)); registerCommand(new Command("shortcuts", "help.shortcuts", CommandKind.HELP_SUBJECT)); diff --git a/src/jdk.jshell/share/classes/jdk/internal/jshell/tool/resources/l10n.properties b/src/jdk.jshell/share/classes/jdk/internal/jshell/tool/resources/l10n.properties index 0d7e517f185..5c405b6e821 100644 --- a/src/jdk.jshell/share/classes/jdk/internal/jshell/tool/resources/l10n.properties +++ b/src/jdk.jshell/share/classes/jdk/internal/jshell/tool/resources/l10n.properties @@ -46,7 +46,7 @@ jshell.err.file.not.found = File ''{1}'' for ''{0}'' is not found. jshell.err.file.exception = File ''{1}'' for ''{0}'' threw exception: {2} jshell.err.file.filename = ''{0}'' requires a filename argument. -jshell.err.startup.unexpected.exception = Unexpected exception reading start-up: {0} +jshell.err.startup.unexpected.exception = Unexpected exception reading startup: {0} jshell.err.unexpected.exception = Unexpected exception: {0} jshell.err.invalid.command = Invalid command: {0} @@ -104,9 +104,9 @@ For example ''/help /list'' or ''/help intro''.\n\ Subjects:\n\ \n -jshell.err.no.snippet.with.id = No snippet with id: {0} +jshell.err.no.snippet.with.id = No snippet with ID: {0} jshell.err.end.snippet.range.less.than.start = End of snippet range less than start: {0} - {1} -jshell.err.range.requires.id = Snippet ranges require snippet ids: {0} +jshell.err.range.requires.id = Snippet ranges require snippet IDs: {0} jshell.err.exit.not.expression = The argument to /exit must be a valid integer expression, it is not an expression: {0} jshell.err.exit.bad.type = The argument to /exit must be a valid integer expression. The type is {1} : {0} @@ -114,7 +114,7 @@ jshell.err.exit.bad.value = The argument to /exit has bad value is {1} : {0} jshell.err.drop.arg =\ In the /drop argument, please specify an import, variable, method, or class to drop.\n\ -Specify by id or name. Use /list to see ids. Use /reset to reset all state. +Specify by ID or name. Use /list to see IDs. Use /reset to reset all state. jshell.err.failed = Failed. jshell.msg.native.method = Native Method jshell.msg.unknown.source = Unknown Source @@ -193,15 +193,15 @@ For more information see:\n\ /help shortcuts help.usage = \ -Usage: jshell