Hi All,
I am new to eclipse plug-in development. I have created a plug-in
and tested the same using the “Launch an Eclipse application”. It
is working fine in this case.
I then created a plug-in jar using the “Export-Wizard”
and placed the jar into the plug-in directory. However when I launch eclipse and
try to access the preferences page; I get the error as “Could not create
action delegate for id: jcv.action.DefinePqmMenuAction”. This is due to a
ClassNotFoundException.
I guess this problem has been encountered before. I am
currently stuck up with this issue and am unable to proceed. Kindly guide me.
Provided below is the log details-
eclipse.buildId=M20060628-1325
java.version=1.4.2_03
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_US
Command-line arguments: -os win32 -ws win32 -arch x86
Error
Mon Nov 05 20:16:14 GMT+05:30 2007
Plug-in JavaCodeValidator was unable to load class
jcv.action.DefinePqmMenuAction.
java.lang.ClassNotFoundException:
jcv.action.DefinePqmMenuAction
at
org.eclipse.osgi.framework.internal.core.BundleLoader.findClass(BundleLoader.java:407)
at
org.eclipse.osgi.framework.internal.core.BundleLoader.findClass(BundleLoader.java:352)
at
org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:83)
at
java.lang.ClassLoader.loadClass(Unknown Source)
at
org.eclipse.osgi.framework.internal.core.BundleLoader.loadClass(BundleLoader.java:276)
at
org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:227)
at
org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1245)
at
org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:147)
at
org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:759)
at
org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
at
org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:51)
at
org.eclipse.ui.internal.WorkbenchPlugin$1.run(WorkbenchPlugin.java:242)
at
org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:67)
at
org.eclipse.ui.internal.WorkbenchPlugin.createExtension(WorkbenchPlugin.java:238)
at
org.eclipse.ui.internal.PluginAction.createDelegate(PluginAction.java:120)
at
org.eclipse.ui.internal.PluginAction.runWithEvent(PluginAction.java:225)
at
org.eclipse.ui.internal.WWinPluginAction.runWithEvent(WWinPluginAction.java:229)
at
org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:539)
at
org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:488)
at
org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:400)
at
org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
at
org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:928)
at
org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3348)
at
org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2968)
at
org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1914)
at
org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1878)
at
org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:419)
at
org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
at
org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:95)
at
org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:78)
at
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:92)
at
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:68)
at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:400)
at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:177)
at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at
java.lang.reflect.Method.invoke(Unknown Source)
at
org.eclipse.core.launcher.Main.invokeFramework(Main.java:336)
at
org.eclipse.core.launcher.Main.basicRun(Main.java:280)
at
org.eclipse.core.launcher.Main.run(Main.java:977)
at
org.eclipse.core.launcher.Main.main(Main.java:952)
The manifest file is –
Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: JavaCodeValidator
Bundle-SymbolicName:
JavaCodeValidator; singleton:=true
Bundle-Version: 1.0.0
Bundle-Activator:
jcv.activator.JcvActivator
Bundle-Localization: plugin
Require-Bundle: org.eclipse.ui,
org.eclipse.core.runtime,
org.eclipse.core.resources,
org.eclipse.jdt.core,
org.eclipse.jface.text,
org.eclipse.ui.workbench.texteditor,
org.eclipse.ui.ide,
org.eclipse.core.filebuffers,
org.eclipse.jdt.ui,
org.eclipse.ltk.core.refactoring,
org.eclipse.ltk.ui.refactoring
Eclipse-LazyStart: false
Bundle-ClassPath: lib/ant-23.jar,
lib/commons-beanutils.jar,
lib/commons-collections.jar,
lib/commons-lang.jar,
lib/commons-logging.jar,
lib/commons-validator.jar,
lib/xercesImpl.jar
The plugin.xml file –
<?xml version="1.0"
encoding="UTF-8"?>
<?eclipse
version="3.2"?>
<plugin>
<extension
point="org.eclipse.ui.actionSets">
<actionSet
label="Java Code Validator"
visible="true"
id="JavaCodeValidatorActionSet">
<menu
label="Java &Code Validator"
id="JavaCodeValidatorMenu">
<separator
name="JavaCodeValidatorMenuGroup">
</separator>
</menu>
<action
label="Validate Java Code"
icon="icons/jcv.GIF"
class="jcv.action.JcvMenuAction"
tooltip="Validate Java Code "
menubarPath="JavaCodeValidatorMenu/JavaCodeValidatorMenuGroup"
toolbarPath="JavaCodeValidatorMenuGroup"
id="jcv.action.JcvMenuAction">
</action>
<action
label="Define Preferences"
class="jcv.action.DefinePreferencesMenuAction"
tooltip="Define Preferences"
menubarPath="JavaCodeValidatorMenu/JavaCodeValidatorMenuGroup"
id="jcv.action.DefinePreferencesMenuAction">
</action>
<action
label="Define PQM Parameters"
class="jcv.action.DefinePqmMenuAction"
tooltip="Define PQM Parameters"
menubarPath="JavaCodeValidatorMenu/JavaCodeValidatorMenuGroup"
id="jcv.action.DefinePqmMenuAction">
</action>
</actionSet>
</extension>
<extension
point="org.eclipse.ui.preferencePages">
<page
id="JavaCodeValidatorPage"
name="Java
Code Validator"
class="jcv.preference.JcvPreferencePage">
</page>
<page
id="JcvJavaDocSettings"
name="Java
Doc Settings"
class="jcv.preference.JcvPreferencePage"
category="JavaCodeValidatorPage">
</page>
</extension>
</plugin>
Any suggestion very appreciated... Thanking you in advance!!!
Thanks & Regards,
Sriram