Running my eclipse plugin end up with ClassNotFoundException

◇◆丶佛笑我妖孽 提交于 2019-12-11 20:33:02

问题


I am trying to develop an eclipse plugin that adds an action to the right click menu. I have created a java project with plugin.xml, and added the related java class that invokes an action on java files(ActionDelegate). When i run this code as "eclipse application", the class is being invoked and everything works as i expected.

The problem is when i convert this project to "plug-in project" via eclipse in order to create plug-in, and run it again as "eclipse application", then i get ClassNotFoundException on the java class i have created.

On the process of converting this project to "plug-in project" eclipse adds a MANIFEST.MF, which related to OSGI bundles. If i remove this file - all works well, and if i add the MANIFEST.MF file - again i get the above ClassNotFoundException, so probably there is something wrong with the MANIFEST.MF and the project representation as plug-in.

Also, when i try to export this plug-in as "Deployable plug-ins and fragments" and install it into host Repository i get the following error: Could not find the exported unit with id: MyReloader version: 1.0.0.201304210902.

any help will be appreciated


回答1:


looks like it is an eclipse version issue, or jre used. once i switched to a different jre, it worked well



来源:https://stackoverflow.com/questions/16128453/running-my-eclipse-plugin-end-up-with-classnotfoundexception

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!