Hi Brain,
Thanks a lot for your solution… the plug-in
worked fine after the change in the Bundle-Classpath.
Once again thanks a lot for your timely help!!!!
Thanks & Regards,
Sriram
From: pde-dev-bounces@xxxxxxxxxxx [mailto:pde-dev-bounces@xxxxxxxxxxx] On Behalf Of Brian Bauman
Sent: Tuesday, November 06, 2007
10:31 PM
To: Eclipse
PDE general developers list.
Cc: 'Eclipse
PDE general developers list.'; pde-dev-bounces@xxxxxxxxxxx
Subject: RE: [pde-dev] Plug-in was
unable toloadclass jcv.action.DefinePqmMenuAction.
I think we have a solution. In the Manifest, you
need to add "." to your Bundle-Classpath.
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,
.
Here is the reason. in your build.properties, "source." is the
prefix used to designated the library for which a source folder represents. By
default (which is also you situation), this library will be ".". The
runtime will search the entries on the Bundle-Classpath to load classes. Since
"." is not on the Bundle-Classpath, the runtime will never find the
library which contains the code from your source folder. Let me know if
adding "." solves the problem.
Brian
Bauman
IBM Software Group - Austin,
TX
Eclipse Committer
baumanbr@xxxxxxxxxx
(512) 838 -2938 (T/L 678-2938)
From:
|
Sriram Hariharasubramanian
<Sriram_H@xxxxxxxxxxx>
|
To:
|
"'Eclipse PDE general
developers list.'" <pde-dev@xxxxxxxxxxx>
|
Cc:
|
"pde-dev-bounces@xxxxxxxxxxx"
<pde-dev-bounces@xxxxxxxxxxx>
|
Date:
|
11/05/2007 11:31 PM
|
Subject:
|
RE: [pde-dev] Plug-in was unable to
loadclass jcv.action.DefinePqmMenuAction.
|
Hi Brian,
Thanks a lot for your quick response.
The referred class is from the source folder. In my eclipse
project, the file is under the package hierarchy <<project-name>> /
src / jcv / action.
Inside the plug-in jar the corresponding java file
“DefinePqmMenuAction” is packaged under “jcv\action”
The jar tree is –
JavaCodeValidator_1.0.0.jar
jcv
action
activator ….
lib
<< all external jars >>
meta-inf
manifest.mf
plugin.xml
The build properties file is below-
source..
= src/
output..
= bin/
bin.includes
= plugin.xml,\
META-INF/,\
.,\
icons/,\
html/,\
*.xml,\
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
Please guide me accordingly.
Thanks & Regards,
Sriram
From: pde-dev-bounces@xxxxxxxxxxx [mailto:pde-dev-bounces@xxxxxxxxxxx] On Behalf Of Brian Bauman
Sent: Monday, November 05, 2007 8:56 PM
To: Eclipse PDE general developers list.
Cc: 'pde-dev@xxxxxxxxxxx'; pde-dev-bounces@xxxxxxxxxxx
Subject: Re: [pde-dev] Plug-in was unable to loadclass
jcv.action.DefinePqmMenuAction.
Hi Sriram,
Welcome to PDE :) You are right, this is a common problem so lets see
what we can do to help.
I take it this class is in a source folder in your project. If not, where
is this class suppose to be coming from (which jar)? If so, could you
send your build.properties file. One of the most common errors,
especially when it does not run after export, is that the bundle is not be
assembled properly. The build.properties is responsible for this and
therefore is a good place to start if your class is suppose to come from a
source folder.
Brian Bauman
IBM Software Group - Austin,
TX
Eclipse Committer
baumanbr@xxxxxxxxxx
(512) 838 -2938 (T/L 678-2938)
From:
|
Sriram Hariharasubramanian
<Sriram_H@xxxxxxxxxxx>
|
To:
|
"'pde-dev@xxxxxxxxxxx'"
<pde-dev@xxxxxxxxxxx>
|
Date:
|
11/05/2007 09:14 AM
|
Subject:
|
[pde-dev] Plug-in was unable to load class
jcv.action.DefinePqmMenuAction.
|
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
**************** CAUTION - Disclaimer
*****************
This e-mail contains PRIVILEGED AND CONFIDENTIAL INFORMATION intended solely
for the use of the addressee(s). If you are not the intended recipient,
please notify the sender by e-mail and delete the original message. Further,
you are not to copy, disclose, or distribute this e-mail or its contents to
any other person and any such actions are unlawful. This e-mail may contain
viruses. Infosys has taken every reasonable precaution to minimize this risk,
but is not liable for any damage you may sustain as a result of any virus in
this e-mail. You should carry out your own virus checks before opening the
e-mail or attachment. Infosys reserves the right to monitor and review the
content of all messages sent to or from this e-mail address. Messages sent to
or from this e-mail address may be stored on the Infosys e-mail system.
***INFOSYS******** End of Disclaimer ********INFOSYS***
|
_______________________________________________
pde-dev mailing list
pde-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/pde-dev_______________________________________________
pde-dev mailing list
pde-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/pde-dev