Usage of API documented as @since 1.8+ maven
this may useful when development is performed under newer sdk version as the target platform for productionthis
pom.xml中的配置是:.net
<plugin> <artifactId>maven-compiler-plugin</artifactId> <version>3.8.0</version> </plugin>
方法一:打開Project Structure,選中側邊欄的Modules,在Sources窗口中修改Language Level(必須大於等於報錯信息給出的level)code
方法二:修改pom.xml爲orm
<plugin> <artifactId>maven-compiler-plugin</artifactId> <version>3.8.0</version> <configuration> <source>11</source> <target>11</target> </configuration> </plugin>