JavaWeb项目运行报错:Failed to instantiate [com.sun.tools.xjc.model.Model]

来源:互联网 发布:主力如何拉升股价 知乎 编辑:程序博客网 时间:2024/05/21 06:00

JavaWeb项目运行报错

org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.sun.tools.xjc.model.Model]: No default constructor found; nested exception is java.lang.NoSuchMethodException: com.sun.tools.xjc.model.Model.<init>()

原因:com.sun.tools.xjc.model.Model包初始化失败,发现是导错了包

解决办法:在Controller类中删除import com.sun.tools.xjc.model.Model;

重新导入org.springframework.ui.Model这个包

重启服务器,项目正常。

阅读全文
0 0
原创粉丝点击