Closed Alice52 closed 3 years ago
delete java.exe, javaw.exe, javaws.exe in follow directory
java.exe, javaw.exe, javaws.exe
JDK11: default no jre, need run follow command ro generate jre
bin\jlink.exe --module-path jmods --add-modules java.desktop --output jre
JDK10: C:\Program Files (x86)\Common Files\Oracle\Java\javapath
C:\Program Files (x86)\Common Files\Oracle\Java\javapath
JDK8: C:\Windows\System32
C:\Windows\System32
switch in pom.xml
<!-- method1 --> <properties> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <maven.compiler.source>11</maven.compiler.source> <maven.compiler.target>11</maven.compiler.target> </properties> <!-- method1 --> <build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <version>3.8.1</version> <configuration> <source>10</source> <target>10</target> <encoding>UTF-8</encoding> </configuration> </plugin> </plugins> </build>
use JDK 10 as project SDK in IDEA
choose 10 as project language level in IDEA
choose compile SDK in IDEA
delete
java.exe, javaw.exe, javaws.exe
in follow directoryJDK11: default no jre, need run follow command ro generate jre
JDK10:
C:\Program Files (x86)\Common Files\Oracle\Java\javapath
JDK8:
C:\Windows\System32
switch in pom.xml
use JDK 10 as project SDK in IDEA
choose 10 as project language level in IDEA
choose compile SDK in IDEA
reference