Java Maven在编译时抛出IllegalCharsetNameException

Java Maven在编译时抛出IllegalCharsetNameException,java,maven,Java,Maven,当我用Maven编译代码时,我得到以下错误 有人能解释一下为什么会发生这种情况并帮我解决吗 我的错误: [INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] Total time

当我用Maven编译代码时,我得到以下错误

有人能解释一下为什么会发生这种情况并帮我解决吗

我的错误:

[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.269 s
[INFO] Finished at: 2017-04-13T13:59:38+02:00
[INFO] Final Memory: 11M/307M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.6.1:compile (default-compile) on project panima: Fatal error compiling: CompilerException: IllegalCharsetNameException -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

Process finished with exit code 1

可能您的编译器编码属性不足,请尝试在pom中添加以下内容:

<properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>

UTF-8

可能您的编译器编码属性缺失,请尝试在pom中添加以下内容:

<properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>

UTF-8

在您发布的输出行上方可能有更多信息。你能看看是否有更多相关信息吗?在你发布的输出行上方可能有更多信息。你能看看是否还有更多的相关信息吗?