解决: 选中有感叹号的项目右键,用maven>>update project解决。[然后我再添加java system 类库就可以了] 转载于:https://www.cnblogs.com/qq1871707128/p/7985241.html