无需下载全新版本。你真正想要的是:
-target version
Generate class files that target a specified version of the VM. Class files will run on the specified target and on later versions, but not on earlier versions of the VM. Valid targets are 1.1, 1.2, 1.3, 1.4, 1.5 (also 5), 1.6 (also 6), and 1.7 (also 7).
The default for -target depends on the value of -source:
If -source is not specified, the value of -target is 1.7
If -source is 1.2, the value of -target is 1.4
If -source is 1.3, the value of -target is 1.4
If -source is 1.5, the value of -target is 1.7
If -source is 1.6, the value of -target is 1.7
For all other values of -source, the value of -target is the value of -source.
从这个来源。-target
并-source
允许控制目标 JVM 和源代码级别。正如消息来源所说,值target
将默认为您提供的值,但您可以根据需要控制两者。
如果此选项无法为您提供足够具体的版本,尽管我无法想象您为什么需要如此精确的版本,那么您只需要硬着头皮自己下载正确的版本