我是靠谱客的博主 无私项链,这篇文章主要介绍解决maven打包 错误: 程序包com.sun.istack.internal不存在 - BBSMAX,现在分享给大家,希望可以做个参考。

**

解决maven打包 错误: 程序包com.sun.istack.internal不存在 - BBSMAX

**使用com.sun.istack.internal.Nullable包时能正常引用,但是使用maven项目打包jar时报错。

在这里插入图片描述
在使用maven打包时报错信息如下

[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] /F:/rbcx/rbjc/src/main/java/cn/edu/zut/pro/rbjc/config/intercepors/LoginInterceptor.java:[5,31] 程序包com.sun.istack.internal不存在
[ERROR] /F:/rbcx/rbjc/src/main/java/cn/edu/zut/pro/rbjc/config/intercepors/LoginInterceptor.java:[53,103] 找不到符号
符号: 类 Nullable
位置: 类 cn.edu.zut.pro.rbjc.config.intercepors.LoginInterceptor
[ERROR] /F:/rbcx/rbjc/src/main/java/cn/edu/zut/pro/rbjc/config/intercepors/LoginInterceptor.java:[56,108] 找不到符号
符号: 类 Nullable
位置: 类 cn.edu.zut.pro.rbjc.config.intercepors.LoginInterceptor
[INFO] 3 errors
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 6.263 s
[INFO] Finished at: 2019-05-16T15:07:59+08:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile) on project rbjc: Compilation failure: Compilation failure:
[ERROR] /F:/rbcx/rbjc/src/main/java/cn/edu/zut/pro/rbjc/config/intercepors/LoginInterceptor.java:[5,31] 程序包com.sun.istack.internal不存在
[ERROR] /F:/rbcx/rbjc/src/main/java/cn/edu/zut/pro/rbjc/config/intercepors/LoginInterceptor.java:[53,103] 找不到符号
[ERROR] 符号: 类 Nullable
[ERROR] 位置: 类 cn.edu.zut.pro.rbjc.config.intercepors.LoginInterceptor
[ERROR] /F:/rbcx/rbjc/src/main/java/cn/edu/zut/pro/rbjc/config/intercepors/LoginInterceptor.java:[56,108] 找不到符号
[ERROR] 符号: 类 Nullable
[ERROR] 位置: 类 cn.edu.zut.pro.rbjc.config.intercepors.LoginInterceptor
[ERROR] -> [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/MojoFailureException

添加一下依赖重新打包

复制代码
1
2
3
4
5
6
7
8
9
10
11
12
<dependency> <groupId>com.sun.xml.bind</groupId> <artifactId>jaxb-impl</artifactId> <version>2.2.11</version> </dependency> <dependency> <groupId>org.jetbrains</groupId> <artifactId>annotations</artifactId> <version>13.0</version> </dependency>

最后

以上就是无私项链最近收集整理的关于解决maven打包 错误: 程序包com.sun.istack.internal不存在 - BBSMAX的全部内容,更多相关解决maven打包内容请搜索靠谱客的其他文章。

本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
点赞(69)

评论列表共有 0 条评论

立即
投稿
返回
顶部