我正在使用 intellij,我的代码使用
import javax.xml.bind.annotation.XmlRootElement;
当我使用命令行时它会编译并运行。但是,当尝试使用 ide(intellij) 运行测试类时,会出现错误
package javax.xml.bind.annotation does not exists
我在 pom.xml 中添加了 jaxb 依赖项
<dependency>
<groupId>javax.xml.bind</groupId>
<artifactId>jaxb-api</artifactId>
<version>2.0</version>
</dependency>
是什么力量intellij
不检测到这一点?