Skip to content

Commit

Permalink
Reflecting review feedback:
Browse files Browse the repository at this point in the history
- using "conciseVersionString" intead of "shortVersionString"
- using <jarfile>.jar <jarfile>
  • Loading branch information
lahodaj committed Nov 12, 2024
1 parent b4d7b49 commit e9e9ad4
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions src/java.base/share/classes/java/lang/System.java
Original file line number Diff line number Diff line change
Expand Up @@ -2790,8 +2790,8 @@ public boolean allowSecurityManager() {
}

@Override
public String shortVersionString() {
return VersionProps.shortVersionString();
public String conciseVersionString() {
return VersionProps.conciseVersionString();
}

});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ class VersionProps {

}

static String shortVersionString() {
static String conciseVersionString() {
return launcher_name + " " + java_version
+ " " + java_version_date
+ (isLTS ? " LTS" : "");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -639,5 +639,5 @@ StackWalker newStackWalkerInstance(Set<StackWalker.Option> options,
/**
* Return a short version string for this runtime.
*/
String shortVersionString();
String conciseVersionString();
}
Original file line number Diff line number Diff line change
Expand Up @@ -595,7 +595,7 @@ static void printXUsageMessage(boolean printToStderr) {
*/
static void printConciseUsageMessage(boolean printToStderr) {
initOutput(printToStderr);
ostream.println(SharedSecrets.getJavaLangAccess().shortVersionString());
ostream.println(SharedSecrets.getJavaLangAccess().conciseVersionString());
ostream.println();
ostream.println(getLocalizedMessage("java.launcher.opt.concise.header",
File.pathSeparator));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -235,10 +235,10 @@ The following options are macOS specific:\n\
# Translators please note do not translate the options themselves
java.launcher.opt.concise.header = Usage: java [java options...] <application> [application arguments...]\n\n\
\Where <application> is one of:\n\
\ <mainclass> to execute the main method of a compiled class\n\
\ -jar <jarfile>.jar to execute the main class of a JAR archive\n\
\ <mainclass> to execute the main method of a compiled main class\n\
\ -jar <jarfile> to execute the main class of a JAR archive\n\
\ -m <module>[/<mainclass>] to execute the main class of a module\n\
\ <sourcefile>.java to compile and execute a source-file program\n\n\
\ <sourcefile> to compile and execute a source-file program\n\n\
\Where key java options include:\n\
\ --class-path <class path>\n\
\ where <class path> is a list of directories and JAR archives to search for class files, separated by "{0}"\n\
Expand Down

0 comments on commit e9e9ad4

Please sign in to comment.