java - Why i cant access the classes of my Eclipse plugin at Runtime? -


i’m developing eclipse plugin, com.simple.plugin, following structure: plugin structure

the problem during runtime cant access classes of own plugin. example if following code inside samplehandler.java:

class cls = class.forname("com.simple.handlers.samplehandler"); object obj = cls.newinstance(); 

i error:

java.lang.classnotfoundexception: com.simple.handlers.samplehandler cannot found com.simple.plugin_1.0.0.qualifier* 

my manifest runtime option classpath have root of plug-in, dont know wrong!

your samplehander class in com.simple.plugin.handlers package not com.simple.handlers package. correct code is:

class<?> cls = class.forname("com.simple.plugin.handlers.samplehandler"); 

you must specify full package name of class want.


Comments

Popular posts from this blog

php - Wordpress website dashboard page or post editor content is not showing but front end data is showing properly -

How to get the ip address of VM and use it to configure SSH connection dynamically in Ansible -

javascript - Get parameter of GET request -