简体   繁体   English

来自Maven依赖的类未在Eclipse“开放类型”中列出

[英]Class from maven dependency is not listed in eclipse “Open Type”

I am having a maven project that has few maven dependencies. 我有一个几乎没有Maven依赖项的Maven项目。 Out of those dependencies, there is a custom jar coming from our custom maven repo. 在这些依赖项之外,还有来自我们的自定义Maven存储库的自定义jar。

When try to search for the classes from that custom jar using ' Open Type ', I am unable to see the classes. 当尝试使用“ Open Type ”从该自定义jar中搜索类时,我看不到这些类。 But I see the jar is available under ' Maven Dependencies ' of the project. 但是我看到该jar在该项目的“ Maven Dependencies ”下可用。 Also I am able to use the classes from the jar in my project. 我还可以在项目中使用jar中的类。

PS: PS:

  • When I run tests from the project I get " ClassNotFoundException " for the classes from that Jar. 当我从项目中运行测试时,对于该Jar中的类,我会收到“ ClassNotFoundException ”。 Not sure if there is a relation between this and the issue of eclipse unable to list it in "Open Type". 不知道这与eclipse的问题之间是否存在关系,无法在“ Open Type”中列出它。

There might be multiple reasons: 可能有多种原因:

  1. try mvn eclipse:eclipse 尝试mvn eclipse:eclipse
  2. try in package explorer 尝试安装资源管理器

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM