本文针对新人,高手请移步。

拿到公司的一个meaven项目,运行其中一个文件的main方法,提示editor does not contain a main type。

在eclipse里面创建项目,都是有默认的项目结构,默认的java源码路径以及class文件输出路径。

由于公司项目和eclipse的默认项目结构不同,导致eclipse默认的源码路径有问题,所以需要在eclipse中配置路径,如下:

右键单击项目——>build path——>configure build path


eclipse 中 editor does not contain a main type错误

删掉source下原有的路径,添加自己项目中的源码文件夹即可。

相关文章:

  • 2021-07-02
  • 2022-01-21
  • 2021-10-31
  • 2021-11-01
  • 2021-04-23
  • 2021-04-06
猜你喜欢
  • 2021-09-04
  • 2022-12-23
  • 2021-07-16
  • 2021-06-28
  • 2021-05-08
  • 2021-09-04
  • 2022-12-23
相关资源
相似解决方案