JDeveloper 11.1.1.1.0 - NoClassDefFoundError when jar exists in project

Hi, I've a problem with trying to test a web application in JDev11g IDE. The following is reported:
WARNING: ADF: Adding the following JSF error message:
Unexpected exception caught: org.springframework.beans.factory.BeanCreationException,
msg=Error creating bean with name 'service' defined in class path resource [applicationContext.xml]: Cannot resolve reference to bean 'employeeDao' while setting bean property 'employeeDao';
nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'employeeDao' defined in class path resource [dataAccess.xml]: Instantiation of bean failed;
nested exception is java.lang.NoClassDefFoundError: com/ibatis/sqlmap/client/SqlMapClientThe class reported as not found exists in a jar that I added to the project. Checking for help on the web, I came across the suggestion to include a weblogic.xml descriptor file:
<?xml version = '1.0' encoding = 'windows-1252'?>
<weblogic-web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                  xsi:schemaLocation="http://www.bea.com/ns/weblogic/weblogic-web-app http://www.bea.com/ns/weblogic/weblogic-web-app/1.0/weblogic-web-app.xsd"
                  xmlns="http://www.bea.com/ns/weblogic/weblogic-web-app">
  <container-descriptor>
    <prefer-web-inf-classes>true</prefer-web-inf-classes>
  </container-descriptor>
</weblogic-web-app>I tried this without success.
The application worked fine under JDev 10g.
Any ideas would be gratefully accepted.
Thanks.

Problem is sorted.
As the project was Spring based, I noticed that WLS already had the Spring jars as part of it's installation. Therefore I didn't include Spring jars in my deployment. The error message when the application was run was related to the iBatis jar and was raised by Spring trying to instantiate the beans at startup. Because of this, I assumed that Spring was in the classpath somewhere.
As a check, I added the Spring jars explicitly to the deployment and problem is solved - the iBatis class is found. So a class loading problem somewhere and I have to explicitly deploy Spring.

Similar Messages

  • Is there any way to block PR changes when PO exists in project builder

    Dear All,
    Could you please advice...is there any way to block PR changes (quantity,price, etc) when PO exists in project builder ?
    Many thanks in advance.
    Nies

    Hi Nies,
    If you are not using the material then you can go for Validation, under Operative Structure> Network> Validation.
    Attach the validation with OPSA click on Automatic.
    In the second scenario if you are using Material Component, as Mr.Muralidharan said OPSG there you can restrict the change by selecting Error Message.
    1. Tcode OPSG in Setting see all the object are selected.
    2. Click on Component tab under change in Purchase Order Exist tab select Error.
    Regards'
    Syed

  • NoClassDefFoundError when jar filename contains '#' sign

    Hi,
    I'm running JRE 1.3.0_02 and have the following problem;
    The application I'm trying to run uses a jar which contains a '#' sign in its path (not something I can change 'coz I'm running it from a Synergy CM archive which creates symbolic links to cache objects)
    e.g.
    /some#dir/lib.jar
    or
    /somedir/lib#21321.jar
    The jre does not recognize this and throws an 'ClassDefNotFoundError'. If the jar's location (and filename) does not contain a '#' al works fine. The symbolic link is also not an issue.
    The machine I'm running on is a:
    'SunOS 5.8 Generic_108528-13 sun4u sparc SUNW,Netra-T4'
    TIA

    BTW: the problem does not occur with JVM 1.4.1_02

  • Java.lang.NoClassDefFoundError when opening Sun ONE Studio 4 CE

    Hi! I have installed Sun ONE Studio 4 CE with windows 2000 OS and when I open the runidew.exe, it's application I'm getting an error that says
    " A java.lang.NoClassDefFoundError" and ide.log messsage is this
    Log Session: Saturday, May 17, 2003 3:20:54 PM CST
    System Info: Product Version = Sun ONE Studio 4 update 1, Community Edition (Build 020923)
    IDE Versioning = IDE/1 spec=1.43.3.1 impl=020923
    Operating System = Windows 2000 version 5.0 running on x86
    Java; VM; Vendor = 1.4.0-beta; Java HotSpot(TM) Client VM 1.4.0-beta-b65; Sun Microsystems Inc.
    Java Home = C:\jdk1.4\jre
    System Locale; Encod. = en_US; Cp1252 (f4j_ce)
    Home Dir; Current Dir = C:\Documents and Settings\Administrator.ISSPG_07; e:\Program Files\s1studio\ce\bin
    IDE Install; User Dir = E:\Program Files\s1studio\ce; c:\ide-userdir
    CLASSPATH = E:\Program Files\s1studio\ce\lib\patches\openide-compat.jar;E:\Program Files\s1studio\ce\lib\locale\core_f4j.jar;E:\Program Files\s1studio\ce\lib\locale\core_f4j_ce.jar;E:\Program Files\s1studio\ce\lib\locale\openide_f4j.jar;E:\Program Files\s1studio\ce\lib\core.jar;E:\Program Files\s1studio\ce\lib\openide.jar;E:\Program Files\s1studio\ce\lib\ext\bsh-1_0-fj.jar;E:\Program Files\s1studio\ce\lib\ext\cmd.jar;E:\Program Files\s1studio\ce\lib\ext\crimson.jar;E:\Program Files\s1studio\ce\lib\ext\ddl.jar;E:\Program Files\s1studio\ce\lib\ext\fjscript.jar;E:\Program Files\s1studio\ce\lib\ext\jaas.jar;E:\Program Files\s1studio\ce\lib\ext\jaxp-api.jar;E:\Program Files\s1studio\ce\lib\ext\jh.jar;E:\Program Files\s1studio\ce\lib\ext\logger.jar;E:\Program Files\s1studio\ce\lib\ext\parser.jar;E:\Program Files\s1studio\ce\lib\ext\pbclient.jar;E:\Program Files\s1studio\ce\lib\ext\regexp.jar;E:\Program Files\s1studio\ce\lib\ext\terminalemulator.jar;E:\Program Files\s1studio\ce\lib\ext\xerces.jar;E:\Program Files\s1studio\ce\lib\ext\jdbc20x.zip;C:\jdk1.4\lib\dt.jar;C:\jdk1.4\lib\tools.jar
    Warning: the extension E:\Program Files\s1studio\ce\modules\autoload\ext\saaj-api.jar may be multiply loaded by modules: [E:\Program Files\s1studio\ce\modules\autoload\jaxrpc-ri-module.jar, E:\Program Files\s1studio\ce\modules\autoload\jaxr-ri-module.jar]
    Warning: the extension E:\Program Files\s1studio\ce\modules\autoload\ext\saaj-ri.jar may be multiply loaded by modules: [E:\Program Files\s1studio\ce\modules\autoload\jaxrpc-ri-module.jar, E:\Program Files\s1studio\ce\modules\autoload\jaxr-ri-module.jar]
    Warning: the extension E:\Program Files\s1studio\ce\modules\autoload\ext\xercesImpl.jar may be multiply loaded by modules: [E:\Program Files\s1studio\ce\modules\autoload\jaxrpc-ri-module.jar, E:\Program Files\s1studio\ce\modules\autoload\jaxr-ri-module.jar]
    Warning: the extension E:\Program Files\s1studio\ce\modules\autoload\ext\sax.jar may be multiply loaded by modules: [E:\Program Files\s1studio\ce\modules\autoload\jaxrpc-ri-module.jar, E:\Program Files\s1studio\ce\modules\autoload\jaxr-ri-module.jar]
    Warning: the extension E:\Program Files\s1studio\ce\modules\ext\jasper-runtime.jar may be multiply loaded by modules: [E:\Program Files\s1studio\ce\modules\tomcat40.jar, E:\Program Files\s1studio\ce\modules\jsp-parser.jar]
    Warning: the extension E:\Program Files\s1studio\ce\modules\ext\jasper-compiler.jar may be multiply loaded by modules: [E:\Program Files\s1studio\ce\modules\tomcat40.jar, E:\Program Files\s1studio\ce\modules\jsp-parser.jar]
    Existing modules:
         Ant [org.apache.tools.ant.module/2 2.7.3.1 020923]
         Applet [org.netbeans.modules.applet/1 1.7.4 020923]
         Auto Update [org.netbeans.modules.autoupdate/1 2.1.2.1 020923]
         Bean Patterns [org.netbeans.modules.beans/1 1.7.3.1 020923]
         Built-in CVS Client [org.netbeans.modules.cvsclient/1 1.4.3.1 020923]
         CSS Support [org.netbeans.modules.css/1 0.2.8.1 020923]
         CVS Command-Line Client Backward Compatibility [org.netbeans.modules.vcs.cmdline.compat/1 1.0.2.1 020923]
         Classfile Closure Compiler [com.sun.forte4j.modules.depclass/1 2.2 020923]
         Database Explorer [org.netbeans.modules.db/1 1.5.3.1 020923]
         Database Schema (JDBC Implementation) [com.sun.forte4j.modules.dbmodel.jdbcimpl/1 1.2.1.1 020923]
         Editor [org.netbeans.modules.editor/1 1.8.3.1 020923]
         External HTML Browser [org.netbeans.modules.extbrowser/1 0.3.4 020923]
         File Copy [org.netbeans.modules.filecopy/1 1.6.2.1 020923]
         Form Editor [org.netbeans.modules.form/2 1.7.3.1 020923]
         General Online Help [org.netbeans.modules.usersguide/1 1.9.3.1 020923]
         HTML [org.netbeans.modules.html/1 1.8.4 020923]
         HTTP Monitor [org.netbeans.modules.web.monitor/1 1.5.2 020923]
         HTTP Server [org.netbeans.modules.httpserver/1 1.7.4 020923]
         IDE Core [org.netbeans.core/1 1.1]
         Image [org.netbeans.modules.image/1 1.7.2.1 020923]
         Internationalization [org.netbeans.modules.i18n/1 1.9.3.1 020923]
         Internationalization of Form [org.netbeans.modules.i18n.form/2 1.8.3 020923]
         J2EE Common Library [com.sun.forte4j.j2ee.lib/1 1.2 020923]
         JAR Packager [org.netbeans.modules.jarpackager/2 1.9.3.1 020923]
         JDBC [org.netbeans.modules.jdbc/1 1.2.1.1 020923]
         JPDA Debugger [org.netbeans.modules.debugger.jpda/1 1.9.3.1 020923]
         JSP Parser [org.netbeans.modules.web.jspparser/1 1.0.3 020923]
         JSP Syntax Coloring [org.netbeans.modules.web.core.syntax/1 1.6.3 020923]
         JSP Tag Library Editor [org.netbeans.modules.web.taglibed/1 1.5.2 020923]
         JSP/Servlet [org.netbeans.modules.web.core/1 1.6.3 020923]
         JSP/Servlet (Advanced) [org.netbeans.modules.web.ie/1 1.6.4 020923]
         JSP/Servlet Breakpoint Support [org.netbeans.modules.web.debug/1 1.0.3 020923]
         JSP/Servlet Depl. Descriptor Editing [org.netbeans.modules.web.dd.editors/1 1.0.2 020923]
         Java Source Files [org.netbeans.modules.java/1 1.7.3.1 020923]
         Javadoc [org.netbeans.modules.javadoc/1 1.7.3.1 020923]
         Logger (TraceLogger) [org.netbeans.modules.logger/1 1.4.1.1 020923]
         PointBase Server [com.sun.forte4j.modules.pointbase/1 1.2.1.1 020923]
         Product Registration [com.sun.ffj.modules.registration/1 1.2 020923]
         Projects [org.netbeans.modules.projects/1 1.7.3.1 020923]
         Resource Bundle Syntax Coloring [org.netbeans.modules.properties.syntax/1 1.7.3 020923]
         Resource Bundles [org.netbeans.modules.properties/1 1.7.3.1 020923]
         Schema2Beans Library [org.netbeans.modules.schema2beans/1 1.2.1 020923]
         Sourceless Java Classes [org.netbeans.modules.clazz/1 1.8.3.1 020923]
         Sun ONE Studio Auto Update [org.netbeans.modules.autoupdateffj/1 1.0.1 020923]
         Text [org.netbeans.modules.text/1 1.7.3.1 020923]
         Tomcat 4.0 Server [org.netbeans.modules.web.tomcat.tomcat40/1 1.1.3 020923]
         Tomcat 4.0 Server Autocompilation Support [org.netbeans.modules.web.tomcat.tomcat40.autocompile/1 1.1.2 020923]
         Tools Debugger [org.netbeans.modules.debugger.debug/1 1.9.3.1 020923]
         User Utilities [org.netbeans.modules.utilities/1 1.7.3.1 020923]
         VCS Generic Command-Line Support [org.netbeans.modules.vcs.advanced/1 1.5.3.1 020923]
         Web module support for J2EE assembling [org.netbeans.modules.web.assemblee/1 1.0.2 020923]
         XML Backward Compatibility [org.netbeans.modules.xml/2 0.2.8 020923]
         XML Coloring Backward Compatibility [org.netbeans.modules.xml.editor.coloring/2 0.2.8 020923]
         XML Core [org.netbeans.modules.xml.core/1 0.2.8.1 020923]
         XML Entity Catalog [org.netbeans.modules.xml.catalog/1 0.2.8.1 020923]
         XML Productivity Tools [org.netbeans.modules.xml.tools/1 0.2.8.1 020923]
         XML Text Editor [org.netbeans.modules.xml.text/1 0.2.8.1 020923]
         XML Tree Editor [org.netbeans.modules.xml.tree/1 0.2.8.1 020923]
    [org.netbeans.core.modules] *********** Exception occurred ************
    Sat May 17 15:21:39 CST 2003: org.netbeans.core.modules.InvalidException: Module[org.netbeans.modules.debugger.debug]: Dependency failed on package sun.tools.debug[DebuggerCallback]
    org.netbeans.core.modules.InvalidException: Module[org.netbeans.modules.debugger.debug]: Dependency failed on package sun.tools.debug[DebuggerCallback]
         at org.netbeans.core.modules.ModuleManager.enable(ModuleManager.java:513)
    [catch] at org.netbeans.core.modules.ModuleList.installNew(ModuleList.java:474)
         at org.netbeans.core.modules.ModuleList.trigger(ModuleList.java:418)
         at org.netbeans.core.modules.ModuleSystem.scanForNewAndRestore(ModuleSystem.java:263)
         at org.netbeans.core.NonGui.run(NonGui.java:519)
         at org.netbeans.core.Main.run(Main.java:213)
         at org.openide.TopManager.initializeTopManager(TopManager.java:120)
         at org.openide.TopManager.getDefault(TopManager.java:81)
         at org.netbeans.core.Main.main(Main.java:346)
         at org.netbeans.core.TopThreadGroup.run(TopThreadGroup.java:87)
         at java.lang.Thread.run(Thread.java:579)
    *********** Exception occurred ************
    Sat May 17 15:23:06 CST 2003: java.lang.NullPointerException: <no message>
    java.lang.NullPointerException
         at java.awt.dnd.DropTarget.addNotify(DropTarget.java:454)
         at java.awt.Component.addNotify(Component.java:5271)
         at java.awt.Container.addNotify(Container.java:1949)
         at javax.swing.JComponent.addNotify(JComponent.java:4141)
         at java.awt.Container.addNotify(Container.java:1957)
         at javax.swing.JComponent.addNotify(JComponent.java:4141)
         at java.awt.Container.addNotify(Container.java:1957)
         at javax.swing.JComponent.addNotify(JComponent.java:4141)
         at java.awt.Container.addImpl(Container.java:486)
         at java.awt.Container.add(Container.java:368)
         at org.netbeans.core.ui.ModuleSelectionPanel.initComponents(ModuleSelectionPanel.java:145)
         at org.netbeans.core.ui.ModuleSelectionPanel.addNotify(ModuleSelectionPanel.java:74)
         at org.netbeans.core.ui.ModuleSelectionPanel.readSettings(ModuleSelectionPanel.java:221)
         at org.openide.WizardDescriptor.updateState(WizardDescriptor.java:450)
         at org.netbeans.core.ui.SetupWizard$InitializedWizardDescriptor.updateState(SetupWizard.java:403)
         at org.openide.WizardDescriptor$Listener.actionPerformed(WizardDescriptor.java:948)
         at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1722)
         at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(AbstractButton.java:1775)
         at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:414)
         at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:253)
         at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:261)
         at java.awt.Component.processMouseEvent(Component.java:4906)
         at java.awt.Component.processEvent(Component.java:4732)
         at java.awt.Container.processEvent(Container.java:1337)
         at java.awt.Component.dispatchEventImpl(Component.java:3476)
         at java.awt.Container.dispatchEventImpl(Container.java:1399)
         at java.awt.Component.dispatchEvent(Component.java:3343)
         at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3302)
         at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3014)
         at java.awt.LightweightDispatcher.dispatchEvent(Container.java:2967)
         at java.awt.Container.dispatchEventImpl(Container.java:1373)
         at java.awt.Window.dispatchEventImpl(Window.java:1459)
         at java.awt.Component.dispatchEvent(Component.java:3343)
         at java.awt.EventQueue.dispatchEvent(EventQueue.java:439)
    [catch] at java.awt.EventDispatchThread.pumpOneEvent(EventDispatchThread.java:150)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:136)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:131)
         at java.awt.Dialog.show(Dialog.java:498)
         at org.netbeans.core.NbPresenter.superShow(NbPresenter.java:672)
         at org.netbeans.core.NbPresenter.run(NbPresenter.java:695)
         at org.openide.util.Mutex.doEventAccess(Mutex.java:917)
         at org.openide.util.Mutex.readAccess(Mutex.java:162)
         at org.netbeans.core.NbPresenter.show(NbPresenter.java:676)
         at org.netbeans.core.ui.SetupWizard.show(SetupWizard.java:287)
         at org.netbeans.core.ui.SetupWizard.showSetupWizard(SetupWizard.java:364)
         at org.netbeans.core.NonGui$2.run(NonGui.java:555)
         at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:160)
         at java.awt.EventQueue.dispatchEvent(EventQueue.java:437)
         at java.awt.EventDispatchThread.pumpOneEvent(EventDispatchThread.java:150)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:136)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:131)
         at java.awt.EventDispatchThread.run(EventDispatchThread.java:99)
    *********** Exception occurred ************
    Sat May 17 15:23:17 CST 2003: java.lang.NullPointerException: <no message>
    java.lang.NullPointerException
         at org.netbeans.core.ui.ModuleSelectionPanel.storeSettings(ModuleSelectionPanel.java:236)
         at org.openide.WizardDescriptor.updateState(WizardDescriptor.java:439)
         at org.netbeans.core.ui.SetupWizard$InitializedWizardDescriptor.updateState(SetupWizard.java:403)
         at org.openide.WizardDescriptor$Listener.actionPerformed(WizardDescriptor.java:948)
         at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1722)
         at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(AbstractButton.java:1775)
         at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:414)
         at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:253)
         at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:261)
         at java.awt.Component.processMouseEvent(Component.java:4906)
         at java.awt.Component.processEvent(Component.java:4732)
         at java.awt.Container.processEvent(Container.java:1337)
         at java.awt.Component.dispatchEventImpl(Component.java:3476)
         at java.awt.Container.dispatchEventImpl(Container.java:1399)
         at java.awt.Component.dispatchEvent(Component.java:3343)
         at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3302)
         at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3014)
         at java.awt.LightweightDispatcher.dispatchEvent(Container.java:2967)
         at java.awt.Container.dispatchEventImpl(Container.java:1373)
         at java.awt.Window.dispatchEventImpl(Window.java:1459)
         at java.awt.Component.dispatchEvent(Component.java:3343)
         at java.awt.EventQueue.dispatchEvent(EventQueue.java:439)
    [catch] at java.awt.EventDispatchThread.pumpOneEvent(EventDispatchThread.java:150)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:136)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:131)
         at java.awt.Dialog.show(Dialog.java:498)
         at org.netbeans.core.NbPresenter.superShow(NbPresenter.java:672)
         at org.netbeans.core.NbPresenter.run(NbPresenter.java:695)
         at org.openide.util.Mutex.doEventAccess(Mutex.java:917)
         at org.openide.util.Mutex.readAccess(Mutex.java:162)
         at org.netbeans.core.NbPresenter.show(NbPresenter.java:676)
         at org.netbeans.core.ui.SetupWizard.show(SetupWizard.java:287)
         at org.netbeans.core.ui.SetupWizard.showSetupWizard(SetupWizard.java:364)
         at org.netbeans.core.NonGui$2.run(NonGui.java:555)
         at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:160)
         at java.awt.EventQueue.dispatchEvent(EventQueue.java:437)
         at java.awt.EventDispatchThread.pumpOneEvent(EventDispatchThread.java:150)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:136)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:131)
         at java.awt.EventDispatchThread.run(EventDispatchThread.java:99)
    *********** Exception occurred ************
    Sat May 17 15:23:22 CST 2003: java.lang.NullPointerException: <no message>
    java.lang.NullPointerException
         at org.netbeans.core.ui.ModuleSelectionPanel.storeSettings(ModuleSelectionPanel.java:236)
         at org.openide.WizardDescriptor.resetWizard(WizardDescriptor.java:662)
         at org.openide.WizardDescriptor.access$700(WizardDescriptor.java:49)
         at org.openide.WizardDescriptor$Listener.actionPerformed(WizardDescriptor.java:970)
         at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1722)
         at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(AbstractButton.java:1775)
         at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:414)
         at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:253)
         at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:261)
         at java.awt.Component.processMouseEvent(Component.java:4906)
         at java.awt.Component.processEvent(Component.java:4732)
         at java.awt.Container.processEvent(Container.java:1337)
         at java.awt.Component.dispatchEventImpl(Component.java:3476)
         at java.awt.Container.dispatchEventImpl(Container.java:1399)
         at java.awt.Component.dispatchEvent(Component.java:3343)
         at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3302)
         at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3014)
         at java.awt.LightweightDispatcher.dispatchEvent(Container.java:2967)
         at java.awt.Container.dispatchEventImpl(Container.java:1373)
         at java.awt.Window.dispatchEventImpl(Window.java:1459)
         at java.awt.Component.dispatchEvent(Component.java:3343)
         at java.awt.EventQueue.dispatchEvent(EventQueue.java:439)
    [catch] at java.awt.EventDispatchThread.pumpOneEvent(EventDispatchThread.java:150)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:136)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:131)
         at java.awt.Dialog.show(Dialog.java:498)
         at org.netbeans.core.NbPresenter.superShow(NbPresenter.java:672)
         at org.netbeans.core.NbPresenter.run(NbPresenter.java:695)
         at org.openide.util.Mutex.doEventAccess(Mutex.java:917)
         at org.openide.util.Mutex.readAccess(Mutex.java:162)
         at org.netbeans.core.NbPresenter.show(NbPresenter.java:676)
         at org.netbeans.core.ui.SetupWizard.show(SetupWizard.java:287)
         at org.netbeans.core.ui.SetupWizard.showSetupWizard(SetupWizard.java:364)
         at org.netbeans.core.NonGui$2.run(NonGui.java:555)
         at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:160)
         at java.awt.EventQueue.dispatchEvent(EventQueue.java:437)
         at java.awt.EventDispatchThread.pumpOneEvent(EventDispatchThread.java:150)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:136)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:131)
         at java.awt.EventDispatchThread.run(EventDispatchThread.java:99)
    *********** Exception occurred ************
    Sat May 17 15:23:29 CST 2003: java.lang.NoClassDefFoundError: java/awt/KeyEventPostProcessor
    java.lang.NoClassDefFoundError: java/awt/KeyEventPostProcessor
         at java.lang.ClassLoader.defineClass0(Native Method)
         at java.lang.ClassLoader.defineClass(ClassLoader.java:495)
         at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:110)
         at java.net.URLClassLoader.defineClass(URLClassLoader.java:249)
         at java.net.URLClassLoader.access$100(URLClassLoader.java:57)
         at java.net.URLClassLoader$1.run(URLClassLoader.java:196)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.net.URLClassLoader.findClass(URLClassLoader.java:189)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:304)
         at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:287)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:260)
         at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
         at java.lang.Class.forName0(Native Method)
         at java.lang.Class.forName(Class.java:130)
         at org.netbeans.core.windows.frames.NbFocusManager.install(NbFocusManager.java:58)
         at org.netbeans.core.windows.frames.SplitContainerImpl.<init>(SplitContainerImpl.java:116)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:33)
         at sun.reflect.InflatableConstructorAccessorImpl.newInstance(InflatableConstructorAccessorImpl.java:38)
         at java.lang.reflect.Constructor.newInstance(Constructor.java:273)
         at java.lang.Class.newInstance0(Class.java:290)
         at java.lang.Class.newInstance(Class.java:249)
         at org.netbeans.core.windows.frames.WindowTypesManager.createInstance(WindowTypesManager.java:179)
         at org.netbeans.core.windows.frames.WindowTypesManager.createInstance(WindowTypesManager.java:162)
         at org.netbeans.core.windows.frames.WindowTypesManager.createContainer(WindowTypesManager.java:64)
         at org.netbeans.core.windows.ModeImpl.createContainer(ModeImpl.java:1822)
         at org.netbeans.core.windows.ModeImpl.addToContainer(ModeImpl.java:1765)
         at org.netbeans.core.windows.ModeImpl.access$400(ModeImpl.java:77)
         at org.netbeans.core.windows.ModeImpl$1.performCommand(ModeImpl.java:396)
         at org.netbeans.core.windows.DeferredPerformer.processCommand(DeferredPerformer.java:186)
         at org.netbeans.core.windows.DeferredPerformer.putRequest(DeferredPerformer.java:83)
         at org.netbeans.core.windows.ModeImpl.dockInto(ModeImpl.java:377)
         at org.netbeans.core.windows.ModeImpl.dockInto(ModeImpl.java:357)
         at org.netbeans.core.windows.ModeImpl.dockInto(ModeImpl.java:345)
         at org.netbeans.core.windows.WindowManagerImpl$TopComponentManager.doOpen(WindowManagerImpl.java:1456)
         at org.netbeans.core.windows.WindowManagerImpl$TopComponentManager.open(WindowManagerImpl.java:1413)
         at org.openide.windows.TopComponent.open(TopComponent.java:212)
         at org.openide.explorer.ExplorerPanel.open(ExplorerPanel.java:88)
         at org.netbeans.core.NbMainExplorer$ExplorerTab.open(NbMainExplorer.java:536)
         at org.netbeans.core.NbMainExplorer$MainTab.open(NbMainExplorer.java:763)
         at org.netbeans.core.windows.layers.TCRefImpl.performCommand(TCRefImpl.java:163)
         at org.netbeans.core.windows.DeferredPerformer.processCommand(DeferredPerformer.java:186)
         at org.netbeans.core.windows.DeferredPerformer.stateChanged(DeferredPerformer.java:155)
         at org.netbeans.core.windows.StateManager.fireStateChanged(StateManager.java:117)
         at org.netbeans.core.windows.StateManager.setVisibilityState(StateManager.java:142)
         at org.netbeans.core.windows.StateManager.propertyChange(StateManager.java:164)
         at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:333)
         at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:260)
         at java.awt.Component.firePropertyChange(Component.java:6476)
         at org.netbeans.core.windows.MainWindow.doShowWindow(MainWindow.java:232)
         at org.netbeans.core.windows.MainWindow.access$300(MainWindow.java:57)
         at org.netbeans.core.windows.MainWindow$4.run(MainWindow.java:207)
         at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:167)
         at java.awt.EventQueue.dispatchEvent(EventQueue.java:437)
    [catch] at java.awt.EventDispatchThread.pumpOneEvent(EventDispatchThread.java:150)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:136)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:131)
         at java.awt.EventDispatchThread.run(EventDispatchThread.java:99)
    Log Session: Saturday, May 17, 2003 5:23:51 PM CST
    System Info: Product Version = Sun ONE Studio 4 update 1, Community Edition (Build 020923)
    IDE Versioning = IDE/1 spec=1.43.3.1 impl=020923
    Operating System = Windows 2000 version 5.0 running on x86
    Java; VM; Vendor = 1.4.0-beta; Java HotSpot(TM) Client VM 1.4.0-beta-b65; Sun Microsystems Inc.
    Java Home = C:\jdk1.4\jre
    System Locale; Encod. = en_US; Cp1252 (f4j_ce)
    Home Dir; Current Dir = C:\Documents and Settings\Administrator.ISSPG_07; e:\Program Files\s1studio\ce\bin
    IDE Install; User Dir = E:\Program Files\s1studio\ce; c:\ide-userdir
    CLASSPATH = E:\Program Files\s1studio\ce\lib\patches\openide-compat.jar;E:\Program Files\s1studio\ce\lib\locale\core_f4j.jar;E:\Program Files\s1studio\ce\lib\locale\core_f4j_ce.jar;E:\Program Files\s1studio\ce\lib\locale\openide_f4j.jar;E:\Program Files\s1studio\ce\lib\core.jar;E:\Program Files\s1studio\ce\lib\openide.jar;E:\Program Files\s1studio\ce\lib\ext\bsh-1_0-fj.jar;E:\Program Files\s1studio\ce\lib\ext\cmd.jar;E:\Program Files\s1studio\ce\lib\ext\crimson.jar;E:\Program Files\s1studio\ce\lib\ext\ddl.jar;E:\Program Files\s1studio\ce\lib\ext\fjscript.jar;E:\Program Files\s1studio\ce\lib\ext\jaas.jar;E:\Program Files\s1studio\ce\lib\ext\jaxp-api.jar;E:\Program Files\s1studio\ce\lib\ext\jh.jar;E:\Program Files\s1studio\ce\lib\ext\logger.jar;E:\Program Files\s1studio\ce\lib\ext\parser.jar;E:\Program Files\s1studio\ce\lib\ext\pbclient.jar;E:\Program Files\s1studio\ce\lib\ext\regexp.jar;E:\Program Files\s1studio\ce\lib\ext\terminalemulator.jar;E:\Program Files\s1studio\ce\lib\ext\xerces.jar;E:\Program Files\s1studio\ce\lib\ext\jdbc20x.zip;C:\jdk1.4\lib\dt.jar;C:\jdk1.4\lib\tools.jar
    Warning: the extension E:\Program Files\s1studio\ce\modules\autoload\ext\saaj-api.jar may be multiply loaded by modules: [E:\Program Files\s1studio\ce\modules\autoload\jaxrpc-ri-module.jar, E:\Program Files\s1studio\ce\modules\autoload\jaxr-ri-module.jar]
    Warning: the extension E:\Program Files\s1studio\ce\modules\autoload\ext\saaj-ri.jar may be multiply loaded by modules: [E:\Program Files\s1studio\ce\modules\autoload\jaxrpc-ri-module.jar, E:\Program Files\s1studio\ce\modules\autoload\jaxr-ri-module.jar]
    Warning: the extension E:\Program Files\s1studio\ce\modules\autoload\ext\xercesImpl.jar may be multiply loaded by modules: [E:\Program Files\s1studio\ce\modules\autoload\jaxrpc-ri-module.jar, E:\Program Files\s1studio\ce\modules\autoload\jaxr-ri-module.jar]
    Warning: the extension E:\Program Files\s1studio\ce\modules\autoload\ext\sax.jar may be multiply loaded by modules: [E:\Program Files\s1studio\ce\modules\autoload\jaxrpc-ri-module.jar, E:\Program Files\s1studio\ce\modules\autoload\jaxr-ri-module.jar]
    Warning: the extension E:\Program Files\s1studio\ce\modules\ext\jasper-runtime.jar may be multiply loaded by modules: [E:\Program Files\s1studio\ce\modules\tomcat40.jar, E:\Program Files\s1studio\ce\modules\jsp-parser.jar]
    Warning: the extension E:\Program Files\s1studio\ce\modules\ext\jasper-compiler.jar may be multiply loaded by modules: [E:\Program Files\s1studio\ce\modules\tomcat40.jar, E:\Program Files\s1studio\ce\modules\jsp-parser.jar]
    Existing modules:
         Ant [org.apache.tools.ant.module/2 2.7.3.1 020923]
         Applet [org.netbeans.modules.applet/1 1.7.4 020923]
         Auto Update [org.netbeans.modules.autoupdate/1 2.1.2.1 020923]
         Bean Patterns [org.netbeans.modules.beans/1 1.7.3.1 020923]
         Built-in CVS Client [org.netbeans.modules.cvsclient/1 1.4.3.1 020923]
         CSS Support [org.netbeans.modules.css/1 0.2.8.1 020923]
         CVS Command-Line Client Backward Compatibility [org.netbeans.modules.vcs.cmdline.compat/1 1.0.2.1 020923]
         Classfile Closure Compiler [com.sun.forte4j.modules.depclass/1 2.2 020923]
         Database Explorer [org.netbeans.modules.db/1 1.5.3.1 020923]
         Database Schema (JDBC Implementation) [com.sun.forte4j.modules.dbmodel.jdbcimpl/1 1.2.1.1 020923]
         Editor [org.netbeans.modules.editor/1 1.8.3.1 020923]
         External HTML Browser [org.netbeans.modules.extbrowser/1 0.3.4 020923]
         File Copy [org.netbeans.modules.filecopy/1 1.6.2.1 020923]
         Form Editor [org.netbeans.modules.form/2 1.7.3.1 020923]
         General Online Help [org.netbeans.modules.usersguide/1 1.9.3.1 020923]
         HTML [org.netbeans.modules.html/1 1.8.4 020923]
         HTTP Monitor [org.netbeans.modules.web.monitor/1 1.5.2 020923]
         HTTP Server [org.netbeans.modules.httpserver/1 1.7.4 020923]
         IDE Core [org.netbeans.core/1 1.1]
         Image [org.netbeans.modules.image/1 1.7.2.1 020923]
         Internationalization [org.netbeans.modules.i18n/1 1.9.3.1 020923]
         Internationalization of Form [org.netbeans.modules.i18n.form/2 1.8.3 020923]
         J2EE Common Library [com.sun.forte4j.j2ee.lib/1 1.2 020923]
         JAR Packager [org.netbeans.modules.jarpackager/2 1.9.3.1 020923]
         JDBC [org.netbeans.modules.jdbc/1 1.2.1.1 020923]
         JPDA Debugger [org.netbeans.modules.debugger.jpda/1 1.9.3.1 020923]
         JSP Parser [org.netbeans.modules.web.jspparser/1 1.0.3 020923]
         JSP Syntax Coloring [org.netbeans.modules.web.core.syntax/1 1.6.3 020923]
         JSP Tag Library Editor [org.netbeans.modules.web.taglibed/1 1.5.2 020923]
         JSP/Servlet [org.netbeans.modules.web.core/1 1.6.3 020923]
         JSP/Servlet (Advanced) [org.netbeans.modules.web.ie/1 1.6.4 020923]
         JSP/Servlet Breakpoint Support [org.netbeans.modules.web.debug/1 1.0.3 020923]
         JSP/Servlet Depl. Descriptor Editing [org.netbeans.modules.web.dd.editors/1 1.0.2 020923]
         Java Source Files [org.netbeans.modules.java/1 1.7.3.1 020923]
         Javadoc [org.netbeans.modules.javadoc/1 1.7.3.1 020923]
         Logger (TraceLogger) [org.netbeans.modules.logger/1 1.4.1.1 020923]
         PointBase Server [com.sun.forte4j.modules.pointbase/1 1.2.1.1 020923]
         Product Registration [com.sun.ffj.modules.registration/1 1.2 020923]
         Projects [org.netbeans.modules.projects/1 1.7.3.1 020923]
         Resource Bundle Syntax Coloring [org.netbeans.modules.properties.syntax/1 1.7.3 020923]
         Resource Bundles [org.netbeans.modules.properties/1 1.7.3.1 020923]
         Schema2Beans Library [org.netbeans.modules.schema2beans/1 1.2.1 020923]
         Sourceless Java Classes [org.netbeans.modules.clazz/1 1.8.3.1 020923]
         Sun ONE Studio Auto Update [org.netbeans.modules.autoupdateffj/1 1.0.1 020923]
         Text [org.netbeans.modules.text/1 1.7.3.1 020923]
         Tomcat 4.0 Server [org.netbeans.modules.web.tomcat.tomcat40/1 1.1.3 020923]
         Tomcat 4.0 Server Autocompilation Support [org.netbeans.modules.web.tomcat.tomcat40.autocompile/1 1.1.2 020923]
         User Utilities [org.netbeans.modules.utilities/1 1.7.3.1 020923]
         VCS Generic Command-Line Support [org.netbeans.modules.vcs.advanced/1 1.5.3.1 020923]
         Web module support for J2EE assembling [org.netbeans.modules.web.assemblee/1 1.0.2 020923]
         XML Backward Compatibility [org.netbeans.modules.xml/2 0.2.8 020923]
         XML Coloring Backward Compatibility [org.netbeans.modules.xml.editor.coloring/2 0.2.8 020923]
         XML Core [org.netbeans.modules.xml.core/1 0.2.8.1 020923]
         XML Entity Catalog [org.netbeans.modules.xml.catalog/1 0.2.8.1 020923]
         XML Productivity Tools [org.netbeans.modules.xml.tools/1 0.2.8.1 020923]
         XML Text Editor [org.netbeans.modules.xml.text/1 0.2.8.1 020923]
         XML Tree Editor [org.netbeans.modules.xml                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

    I would suggest downloading the latest version of the IDE (v. 5.0) which is available at:
    http://wwws.sun.com/software/sundev/jde/index.html

  • NoClassDefFoundError when trying to return a custom Object

    Hi,
    I'm trying to get some system memory info from a Windows machine using Java. I've written the C code and Java code and it all compiles fine. I can also use most of the methods in the two files. I have a problem with one method though. Its a method that is returning an object type that I created that mirrors a windows structure. Below is the code.
    // Java Object to store the data
    package agent.win32;
    public class MemoryInfo{
      int dwLength;
      int dwMemoryLoad;
      int dwTotalPhys;
      int dwAvailPhys;
      int dwTotalPageFile;
      int dwAvailPageFile;
      int dwTotalVirtual;
      int dwAvailVirtual;
      public int get_dwLength() { return dwLength; }
      public int get_dwMemoryLoad() { return dwMemoryLoad; }
      public int get_dwTotalPhys() { return dwTotalPhys; }
      public int get_dwAvailPhys() { return dwAvailPhys; }
      public int get_dwTotalPageFile() { return dwTotalPageFile; }
      public int get_dwAvailPageFile() { return dwAvailPageFile; }
      public int get_dwTotalVirtual() { return dwTotalVirtual; }
      public int get_dwAvailVirtual() { return dwAvailVirtual; }
    // Java Class that uses JNI
    package agent.win32;
    public class NIMSNT {
      //Constructor
      public NIMSNT(){};
      static{
        try{
          System.loadLibrary("NIMSNT");
        catch (java.lang.UnsatisfiedLinkError e) {
          System.out.println (e);
       * check psapi.dll and psapi functions
       * return true if NT process can be enumerate
      public static native boolean Initialize();
       * Description:The EnumProcesses function retrieves the process identifier
       * for each process object in the system
       * return value:the list of process identifiers
       * call psapi function EnumProcesses
      public static native int[] EnumProcesses();
       * Description:The OpenProcess function returns a handle to an existing process object.
       * return value:If the function succeeds, the return value is an open handle to the specified process
       * call kernel32 function OpenProcess
      public static native int OpenProcess(int Pid);
       * Description:The EnumProcessModules function retrieves a handle for each module in the specified process
       * return value:the list of module handles
       * call psapi function EnumProcessModules
      public static native int[] EnumProcessModules(int hProcess);
       * Description:The GetModuleFileNameEx function retrieves the fully qualified path for the specified module
       * return value:the fully qualified path for the specified module
       * call psapi function GetModuleFileNameEx
      public static native String GetModuleFileName(int hProcess,int hModule);
       * Description:The GetModuleBaseName function retrieves the base name of the specified module
       * return value:the base name of the specified module
       * call psapi function GetModuleBaseName
      public static native String GetModuleBaseName(int hProcess,int hModule);
       * Description:function closes an open object handle
       * return value:true if succesfuly
       * call kernel32 function CloseHandle
      public static native boolean CloseHandle(int handle);
       * Description:function gets system memory
       * return value:String
      public static native MemoryInfo GetSystemMemoryInfo();
    // C Structure (defined in windows.h)
    typedef struct _MEMORYSTATUS {
      DWORD dwLength;
      DWORD dwMemoryLoad;
      SIZE_T dwTotalPhys;
      SIZE_T dwAvailPhys;
      SIZE_T dwTotalPageFile;
      SIZE_T dwAvailPageFile;
      SIZE_T dwTotalVirtual;
      SIZE_T dwAvailVirtual;
    } MEMORYSTATUS, *LPMEMORYSTATUS;
    // C code
    #include <windows.h>
    #include <string.h>
    #include "agent_win32_NIMSNT.h"
    #define MaxProcessNumber 10000
    /** Type Definitions                                  **/
    typedef BOOL (WINAPI *ENUMPROCESSES)(
         DWORD * lpidProcess, 
           DWORD cb,            
           DWORD * cbNeeded     
    typedef BOOL (WINAPI *ENUMPROCESSMODULES)(
         HANDLE hProcess,     
         HMODULE * lphModule, 
         DWORD cb,            
         LPDWORD lpcbNeeded   
    typedef DWORD (WINAPI *GETMODULEFILENAMEEXA)(
         HANDLE hProcess,          
         HMODULE hModule,          
         LPTSTR lpstrFileName,     
         DWORD nSize               
    typedef DWORD (WINAPI *GETMODULEBASENAME)(
         HANDLE hProcess,          
         HMODULE hModule,          
         LPTSTR lpstrFileName,     
         DWORD nSize               
    typedef struct _PROCESS_MEMORY_COUNTERS {
        DWORD cb;
        DWORD PageFaultCount;
        DWORD PeakWorkingSetSize;
        DWORD WorkingSetSize;
        DWORD QuotaPeakPagedPoolUsage;
        DWORD QuotaPagedPoolUsage;
        DWORD QuotaPeakNonPagedPoolUsage;
        DWORD QuotaNonPagedPoolUsage;
        DWORD PagefileUsage;
        DWORD PeakPagefileUsage;
    } PROCESS_MEMORY_COUNTERS, *PPROCESS_MEMORY_COUNTERS;
    typedef BOOL (WINAPI *GETPROCESSMEMORYINFO)(
         HANDLE hProcess,
         PPROCESS_MEMORY_COUNTERS ppsmenCounters,
         DWORD cb
    /** Global Variables                                  **/
    ENUMPROCESSES EnumProcesses;
    ENUMPROCESSMODULES EnumProcessModules;
    GETMODULEFILENAMEEXA GetModuleFileNameExA;
    GETMODULEBASENAME GetModuleBaseName;
    GETPROCESSMEMORYINFO GetProcessMemoryInfo;
    /** DLL Entry                                         **/
    BOOL APIENTRY DllMain(HANDLE hInst, DWORD ul_reason_being_called, LPVOID lpReserved){    
         return TRUE;
    * Class:     nims4_agent_win32_NIMSNT
    * Method:    Initialize
    * Signature: ()Z
    JNIEXPORT jboolean JNICALL Java_agent_win32_NIMSNT_Initialize(JNIEnv * env,jclass clazz){
         HANDLE hpsapi=LoadLibrary("PSAPI.DLL");
         if (hpsapi==NULL) return FALSE;
         EnumProcesses=(ENUMPROCESSES)GetProcAddress((HINSTANCE)hpsapi,"EnumProcesses");
         GetModuleFileNameExA = (GETMODULEFILENAMEEXA)GetProcAddress((HINSTANCE)hpsapi, "GetModuleFileNameExA");
         GetModuleBaseName = (GETMODULEBASENAME)GetProcAddress((HINSTANCE)hpsapi, "GetModuleBaseNameA");
         EnumProcessModules = (ENUMPROCESSMODULES)GetProcAddress((HINSTANCE)hpsapi, "EnumProcessModules");
         GetProcessMemoryInfo = (GETPROCESSMEMORYINFO)GetProcAddress((HINSTANCE)hpsapi, "GetProcessMemoryInfo");
         if (
              NULL == EnumProcesses          ||
              NULL == GetModuleFileName     ||
              NULL == GetModuleBaseName     ||
              NULL == EnumProcessModules  )
            return FALSE;
         return TRUE;   
    * Class:     nims4_agent_win32_NIMSNT
    * Method:    EnumProcesses
    * Signature: ()[I
    JNIEXPORT jintArray JNICALL Java_agent_win32_NIMSNT_EnumProcesses(JNIEnv * env, jclass clazz){
         DWORD aPids[MaxProcessNumber];
         DWORD cGot;
         jintArray Pids=0;
         if(EnumProcesses(aPids,sizeof(aPids),&cGot)){
              cGot /= sizeof(aPids[0]);
                 Pids= (*env)->NewIntArray(env,cGot);
              (*env)->SetIntArrayRegion(env,Pids,0,cGot,(jint*) aPids);
         return Pids;
    * Class:     nims4_agent_win32_NIMSNT
    * Method:    OpenProcess
    * Signature: (IZI)I
    JNIEXPORT jint JNICALL Java_agent_win32_NIMSNT_OpenProcess (JNIEnv * env, jclass clazz,jint Pid){
         return (jint) OpenProcess(PROCESS_QUERY_INFORMATION | PROCESS_VM_READ,FALSE,Pid);
    * Class:     nims4_agent_win32_NIMSNT
    * Method:    EnumProcessModules
    * Signature: (I[I)[I
    JNIEXPORT jintArray JNICALL Java_agent_win32_NIMSNT_EnumProcessModules (JNIEnv * env, jclass clazz, jint hProcess){
         HMODULE hModule[MaxProcessNumber];
         jintArray jModule=0;
         DWORD cGot;    
         if (EnumProcessModules((HANDLE)hProcess,hModule,sizeof(hModule),&cGot)){
              cGot/= sizeof(hModule[0]);
              jModule= (*env)->NewIntArray(env,cGot);
              (*env)->SetIntArrayRegion(env,jModule,0,cGot,(jint*)hModule);
         return jModule;
    * Class:     nims4_agent_win32_NIMSNT
    * Method:    GetModuleFileName
    * Signature: (II)Ljava/lang/String;
    JNIEXPORT jstring JNICALL Java_agent_win32_NIMSNT_GetModuleFileName(JNIEnv * env, jclass clazz, jint hProcess, jint hModule){
         jstring jName=0;
         char FileName[MAX_PATH];
         if(GetModuleFileNameExA((HANDLE)hProcess,(HMODULE)hModule,FileName,sizeof(FileName))!=0){
              jName=(*env)->NewStringUTF(env,FileName);
         return jName;
    * Class:     nims4_agent_win32_NIMSNT
    * Method:    GetModuleBaseName
    * Signature: (II)Ljava/lang/String;
    JNIEXPORT jstring JNICALL Java_agent_win32_NIMSNT_GetModuleBaseName(JNIEnv * env, jclass clazz, jint hProcess, jint hModule){
         jstring jName=0;
         char FileName[MAX_PATH];
         if(GetModuleBaseName((HANDLE)hProcess,(HMODULE)hModule,FileName,sizeof(FileName))!=0){
              jName=(*env)->NewStringUTF(env,FileName);
         return jName;
    * Class:     nims4_agent_win32_NIMSNT
    * Method:    CloseHandle
    * Signature: (I)Z
    JNIEXPORT jboolean JNICALL Java_agent_win32_NIMSNT_CloseHandle(JNIEnv * env, jclass clazz, jint handle)
         return CloseHandle((HANDLE) handle);
    * Class:     nims_agent_win32_NIMSNT
    * Method:    GetSystemMemoryInfo
    * Signature: (I)Lagent/win32/MemoryInfo;
    JNIEXPORT jobject JNICALL Java_agent_win32_NIMSNT_GetSystemMemoryInfo(JNIEnv * env, jclass clazz){
         jfieldID jfield;
         jobject jobj=0;
         MEMORYSTATUS stat;
         stat.dwLength = sizeof(stat);
         GlobalMemoryStatus(&stat);
         clazz=(*env)->FindClass(env,"agent.win32.NIMSMemoryInfo");
         if (clazz==0) return 0;
         jobj = (*env)->AllocObject (env,clazz);
         //set NIMSMemoryInfo object field
         // dwLength
         jfield=(*env)->GetFieldID(env,clazz,"dwLength","I");
         (*env)->SetIntField (env,jobj, jfield,stat.dwLength);
         // dwMemoryLoad
         jfield=(*env)->GetFieldID(env,clazz,"dwMemoryLoad","I");
         (*env)->SetIntField (env,jobj, jfield,stat.dwMemoryLoad);
         // dwTotalPhys
         jfield=(*env)->GetFieldID(env,clazz,"dwTotalPhys","I");
         (*env)->SetIntField (env,jobj, jfield,stat.dwTotalPhys);
         // dwAvailPhys
         jfield=(*env)->GetFieldID(env,clazz,"dwAvailPhys","I");
         (*env)->SetIntField (env,jobj, jfield,stat.dwAvailPhys);
         // dwTotalPageFile
         jfield=(*env)->GetFieldID(env,clazz,"dwTotalPageFile","I");
         (*env)->SetIntField (env,jobj, jfield,stat.dwTotalPageFile);
         // dwAvailPageFile
         jfield=(*env)->GetFieldID(env,clazz,"dwAvailPageFile","I");
         (*env)->SetIntField (env,jobj, jfield,stat.dwAvailPageFile);
         // dwTotalVirtual
         jfield=(*env)->GetFieldID(env,clazz,"dwTotalVirtual","I");
         (*env)->SetIntField (env,jobj, jfield,stat.dwTotalVirtual);
         // dwAvailVirtual
         jfield=(*env)->GetFieldID(env,clazz,"dwAvailVirtual","I");
         (*env)->SetIntField (env,jobj, jfield,stat.dwAvailVirtual);
         return jobj;
    };I can use all of the methods in the Java/C code except for the the last native method   public static native MemoryInfo GetSystemMemoryInfo(); . I get a NoClassDefFoundError when I try to use this method. I have a feeling that I'm just doing something stupid.
    Thanks in advance,
    John

    Yes, exactly. I changed the name of that class and forgot to change it in the c code. Thanks for the feedback.
    Also, if anyone is using this code as an example, you need to change "agent.win32.MemoryInfo" to "agent/win32/MemoryInfo" in the c code. If it is left as "agent.win32.MemoryInfo" you will get a ClassCircularityError when trying to make multiple calls to the NIMSNT.GetSystemMemoryInfo();.

  • NoClassDefFoundError when passing HttpSession

    Hello All,
    I am getting a NoClassDefFoundError when I start my rmi server.
    I am pass an HttpSession as one of the variables of my rmi call.
    Everything worked fine until I added the HttpSession variable.
    Why do I get this exception ?
    Exception in thread "main" java.lang.NoClassDefFoundError: javax/servlet/http/Ht
    tpSession
            at java.lang.Class.getDeclaredMethods0(Native Method)
            at java.lang.Class.privateGetDeclaredMethods(Class.java:2395)
            at java.lang.Class.privateGetPublicMethods(Class.java:2519)
            at java.lang.Class.getMethods(Class.java:1406)
            at sun.rmi.server.Util.getRemoteInterfaces(Util.java:221)
            at sun.rmi.server.Util.getRemoteInterfaces(Util.java:193)
            at sun.rmi.server.Util.createProxy(Util.java:126)
            at sun.rmi.server.UnicastServerRef.exportObject(UnicastServerRef.java:169)
            at java.rmi.server.UnicastRemoteObject.exportObject(UnicastRemoteObject.java:293)
            at java.rmi.server.UnicastRemoteObject.exportObject(UnicastRemoteObject.java:235)
            at java.rmi.server.UnicastRemoteObject.<init>(UnicastRemoteObject.java:133)
            at java.rmi.server.UnicastRemoteObject.<init>(UnicastRemoteObject.java:119)
            at pE.PEg.<init>(PEgImpl.java:36)
            at pE.PEgServer.<init>(PEgServer.java:10)
            at pEngine.PEgServer.main(PEgServer.java:18)If I add server2_2.jar to my class path, then I get this exception:
    java.rmi.ServerError: Error occurred in server thread; nested exception is:
            java.lang.NoClassDefFoundError: javax/servlet/http/HttpSessionWhile were at it, let me ask this: My RMI implementation code has some data that it needs to pass to my servlet that is invoked by an third-party server. I due to the sensitive nature of the data, I don't want to stick it in a DB, but pass as session variables, thus I was passing in the session var. A better way to do this?
    Edited by: jimcsc on Aug 29, 2008 9:58 AM

    I am getting a NoClassDefFoundError when I start my rmi server.That will be because either the server or the Registry or the client doesn't have the class named in the exception in its CLASSPATH.
    I am pass an HttpSession as one of the variables of my rmi call.Are HttpSessions really serializable? This sounds like a very odd design.
    While were at it, let me ask this: My RMI implementation code has some data that it needs to pass to my servlet that is invoked by an third-party server. I due to the sensitive nature of the data, I don't want to stick it in a DB, but pass as session variables, thus I was passing in the session var.There's something wrong with that description. It seems to me that it is the servlet passing the HttpSession to your RMI server, not the other way around. Assuming the HttpSession implementation is serializable it should work but it's still an odd design. I would get the stuff that you actually need out of the HttpSession and pass that.

  • Exception in thread main java.lang.NoClassDefFoundError when Install 11g 2

    Exception in thread main java.lang.NoClassDefFoundError when Install Oracle database 11g release 2 on redhat linux enterprise 5
    My Java Version is 1.6.0_13-b03, can anyone help?
    Error Message as follows:
    准备从以下地址启动 Oracle Universal Installer /tmp/OraInstall2009-12-01_11-25-58AM. 请稍候...[oracle@redhatlinux ~]$ Exception in thread "main" java.lang.NoClassDefFoundError
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:164)
    at java.awt.Toolkit$2.run(Toolkit.java:821)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.awt.Toolkit.getDefaultToolkit(Toolkit.java:804)
    at com.jgoodies.looks.LookUtils.isLowResolution(Unknown Source)
    at com.jgoodies.looks.LookUtils.<clinit>(Unknown Source)
    at com.jgoodies.looks.plastic.PlasticLookAndFeel.<clinit>(PlasticLookAndFeel.java:122)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:242)
    at javax.swing.SwingUtilities.loadSystemClass(SwingUtilities.java:1783)
    at javax.swing.UIManager.setLookAndFeel(UIManager.java:480)
    at oracle.install.commons.util.Application.startup(Application.java:758)
    at oracle.install.commons.flow.FlowApplication.startup(FlowApplication.java:164)
    at oracle.install.commons.flow.FlowApplication.startup(FlowApplication.java:181)
    at oracle.install.commons.base.driver.common.Installer.startup(Installer.java:265)
    at oracle.install.ivw.db.driver.DBInstaller.startup(DBInstaller.java:114)
    at oracle.install.ivw.db.driver.DBInstaller.main(DBInstaller.java:132)

    I am getting the same exception. I tried using xhost_+ but it's still not working for me.
    Again, here is the error that I'm receiving when trying to install Oracle 11g:
    Exception in thread "main" java.lang.NoClassDefFoundError
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:164)
    at java.awt.Toolkit$2.run(Toolkit.java:821)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.awt.Toolkit.getDefaultToolkit(Toolkit.java:804)
    at com.jgoodies.looks.LookUtils.isLowResolution(Unknown Source)
    at com.jgoodies.looks.LookUtils.<clinit>(Unknown Source)
    at com.jgoodies.looks.plastic.PlasticLookAndFeel.<clinit>(PlasticLookAndFeel.java:122)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:242)
    at javax.swing.SwingUtilities.loadSystemClass(SwingUtilities.java:1783)
    at javax.swing.UIManager.setLookAndFeel(UIManager.java:480)
    at oracle.install.commons.util.Application.startup(Application.java:758)
    at oracle.install.commons.flow.FlowApplication.startup(FlowApplication.java:164)
    at oracle.install.commons.flow.FlowApplication.startup(FlowApplication.java:181)
    at oracle.install.commons.base.driver.common.Installer.startup(Installer.java:265)
    at oracle.install.ivw.db.driver.DBInstaller.startup(DBInstaller.java:114)
    at oracle.install.ivw.db.driver.DBInstaller.main(DBInstaller.java:132)
    Thanks in advance for the help!!
    Also, this is all very new to me. So if you could provide a step-by-step answer I would really appreciate it.
    Edited by: user9014123 on Jan 25, 2010 1:40 PM

  • Error: java.lang.NoClassDefFoundError when Automatic Import Service loads

    Hi
    The netware server running NW 6.5sp4a has been reloaded due to hardware
    failure.
    All the data was restored to all volumes.
    When I run zfdstart I get the following error:
    error: java.lang.NoClassDefFoundError when Automatic Import Service loads.
    Help !!!
    Thanks
    Minesh

    [email protected] wrote:
    > error: java.lang.NoClassDefFoundError when Automatic Import Service loads.
    hmm... would say that the zeninstall wasn't correctly done... try
    reinstalling importing..
    Marcus Breiden
    If you are asked to email me information please change -- to - in my e-mail
    address.
    The content of this mail is my private and personal opinion.
    http://www.edu-magic.net

  • NoClassDefFoundError when using URLClassLoader

    Hi,
    I have an applet which tries to load a jar file dynamically. I am giving the code snippet here.
    loader = new URLClassLoader(new URL[] { new URL("http://localhost:4095/jars/dynamicload.jar") });
    m_class = loader.loadClass("loader.DynamicLoadedClass");
    (loader.DynamicLoadedClass) prntr = (loader.DynamicLoadedClass) m_class.newInstance();
    But this is throwing a NoClassDefFoundError when I try to cast the new instance to a DynamicLoadedClass.
    Can anybody help me correct this problem?
    Thanks
    Unni

    It will be happening when your code tries to access loader.DynamicLoadedClass for the cast. When a class accesses another class implicitly it asks the ClassLoader that loaded it for the class. That will presumably be the standard class loader that points to the classpath, and knows nothing about your dynamically loaded class.
    Really if you mention a class to the compiler then there's no point in trying to load it dynamically, since you must already have it locally to do the compilation.
    Usually you know that an dynamically loaded class will conform to some abstract class or interface you have locally, and you cast the new instance to that. That works because standard classloader delegation means your URLClassLoader will take classes from the class path if they are there.

  • NoClassDefFoundError when using ServerErrorListener

    Hi,
    I've got a java-programm using JCo 2.1.6. I wrapped up this programm with the jsl-tool to use that programm as a windows service. Now the connection process stands still when calling addClientPool. Therefore i tried to implement the ServerErrorListener and ServerExceptionListener to check whether I got further information because when I'm running that programm directly all is working well. Now I'm getting a NoClassDefFoundError when starting the programm. I'm a little bit buzzeled what's wrong. What jars do I need to get both listeners?
    Thanks
    Markus

    Hi Markus,
    Both exceptions are located in the jrfc.jar file.
    It can also be the case that one of the exception classes needs another class which is located in another jar, if you get my point. For that you should have a really close look at the log file, what is really causing the noclassdeffounderror.
    Kind regards,
    Peter

  • How to import existing eclipse Project to JDeveloper

    Hi,
         previously I used to use Eclipse IDE. I have started to use Oracle JDeveloper 11.1.2.4.0 now. How can I import my existing Eclipse projects to JDeveloper? Please Note, I already have tried following options -
    "Importing Existing Files into a New JDeveloper Project" from here - Working with Applications and Projects.
    But, When I import the source files from existing Eclipse Projects to JDeveloper, I am not able to crease similar directory structure in the JDeveloper(in Application Navigator). As a result, I can not use my existing ANT build script to build my project[Though JDeveloper build my project,but I want to use manual ANT build.]
    Moreover I don't want to change my existing directory structure as I am working on and existing project and I need to synchronize to my repository(Apache SVN).
    Can any one help me in this - How can I import existing Eclipse Project to JDeveloper? Without any significant change in directory structure.
    Best Regards
    Chandramoulee

    Well there are two options - if you have a WAR file with the code in it, then you can use the file->import WAR.
    Or you can use the new->Project from source code.
    Note that you'll probably need to do some library settings and some directory setting after that.
    Have a look at this demo for basic steps:
    http://download.oracle.com/otn_hosted_doc/jdeveloper/11gdemos/NBtoJDevProject/NBtoJDevProject.html

  • NoClassDefFoundError with jar in WEB-INF/lib

    Hi,
    I have an enterprise application running on Websphere 6. I have one external jar file in WEB-INF\lib (it's commons-lang). I am getting NoClassDefFoundError when trying to use classes in this jar file from the web app -- I thought that it was sufficient to drop the jar in \lib and then it would be picked up but obviously that is not the case.
    As a workaround, I've created a shared lib on the app server for this jar, and added it to the application. This works fine, but I can't understand why is should be required.
    Shouldn't it be sufficient just to put the jar file in WEB-INF\lib under the webapp?

    I think Websphere 6 already includes commons-logging. So the error you are getting may be classloader confusion, which is easy to do with Websphere and hard to understand (so I may be confused here). Try not including it anywhere, not in your web app and not whatever it was you did to make it work. Restart Websphere and your web app and see what happens.

  • The action could not be completed because of a conflict with the original item. The conflict may have occurred when an existing item was updated on another computer or device. Open the item again and try making your changes. If the problem continues, cont

    I have a user on an iMac 10.6 connected to our domain.  She uses Outlook web access for email on our exchange server.  Last week she received the following message which is randomly preventing her from sending emails.  She claims no attachment was involved in the original email when this all started.  I have not been able to look at her account as she is out of the office but maybe someone else dealt with this issue.  I realize this may not be Mac related but thought I'd give it a try.  She did say it occurred once over two days while working on a PC but it continued over the past weekend.
    If an internal user tries to send a message with infected attachment using Outlook Web Access, it may report the following error message: The action could not be completed because of a conflict with the original item. The conflict may have occurred when an existing item was updated on another computer or device. Open the item again and try making your changes. If the problem continues, contact technical support for your organization.
    This is because F-Secure Anti-Virus for Microsoft Exchange has detected a virus in the attachment. If the user tries to send the message again, the message will be sent but without the attachment. At the same time a blank message with an attachment named "Attachment_information.txt" will remain in the user's Drafts folder. The "Attachment_information.txt" will contain information about the virus detected in the message.

    PS - have found other posts indicating that clips smaller than 2s or sometimes 5s, or "short files" can cause this. Modern style editing often uses short takes ! Good grief I cannot believe Apple. Well I deleted a half a dozen short sections and can export, but now of course the video is a ruined piiece of junk and I need to re-do the whole thing, the sound etc. which is basically taking as much time as the original. And each time I re-do it I risk again this lovely error -50 and again trying to figure out what thing bugs it via trial and error instead of a REASONABLE ERROR MESSAGE POINTING TO THE CLIP IT CAN'T PROCESS. What a mess. I HATE this iMovie application - full of BUGS BUGS BUGS which Apple will not fix obviously, since I had this product for a few years and see just hundreds of hits on Google about this error with disappointed users. Such junk I cannot believe I paid money for it and Apple does not support it with fixes !!!
    If anyone knows of a GOOD reasonably priced video editing program NOT from APPLE I am still looking for suggestions. I want to do more video in future, but obviously NOT with iMovie !!!

  • I have consolidate my folders related to the video I am in the progress of working on.  Premiere elements does not follow their new location.  How do I syn them back up all at once so premiere doesn't ask me for their location when I open the project

    I have consolidate my folders related to the video I am in the progress of working on.  Premiere elements does not follow their new location.  How do I syn them back up all at once so premiere doesn't ask me for their location when I open the project

    This is the Photoshop Elements forum, not the Premiere Elements forum, located here:
    https://forums.adobe.com/community/premiere_elements
    When you open the project, it should ask you where the first file is located. After you tell it where it is, it should be able to find the rest of them if they are located near the first one.  Then save the file.  If you move the files again, you will have to relink them again.

  • I imported an hour of video into iMovie HD and cut it down to a 33 sec clip, and emptied the trash.  When I save the project, the file size is 20Gb.  How can I save just the 33 sec clip?

    I imported an hour of video into iMovie HD and cut it down to a 33 sec clip, and emptied the trash.  When I save the project, the file size is 20Gb.  How can I save just the 33 sec clip?

    Non-destructive editing is an important feature of iMovie HD 6.
    iMovie preserves the entire copy of every clip you place into your movie in case you change your mind at a later stage.
    So, if you have cut out one minute from a 45 minute clip, iMovie will have stored two complete copies of that clip. This is why is helps to set import as 3-5 minute clips rather than one huge chunk. As DV runs at 13GB per hour your project files can get very big.
    One workaround is to complete the editing of a section of the movie, then export that to Quicktime: highlight the clip/s, choose Share-Quicktime, turn on Share selected clips only, and choose Full Quality from the pop-ip menu.
    Once you have saved the stand-alone clip to your hard drive, you can re-import it into your project using the File/Import command, and delete the original long clip/s from the project.

Maybe you are looking for

  • P45 Neo2 and Memory

    Before you all start flaming me,  I know that my memory is not "true" 1066 memory. What I want to find out is if there is a way to make it work at that speed stable. Anywho, here's the situation. I've got a P45 Neo2 motherboard that won't accept 4x2G

  • New Monitor, Old Computer Compatibility

    I have a new(ish) Acer monitor. It's only 17.5" apparently, but its native resolution is something like 1600 x 900 and 32-bit colour, though I think it can handle lower resolution if need be. I have a Sawtooth with a Rage 128 Pro graphics card. Will

  • Where is the file that contains the folder view setting?

    I know this questions been asked before but I can't find it and cant remember the answer. There is directory file that holds all the file and folder setting and if a persons deletes it, essentially all the files and folder view setting revert back to

  • Email server down again - why locked?

    Email service down again.... yes - it is 2012 and a company backed by ADOBE, charging a premium price for hosting is more unreliable that a couple of kids working out of their garage. I'm disgusted. No one will give out the names of who is in charge

  • B Channel out of service

    Hi, I am getting B Channel OOS in my event viewer for a gateway in CCM. Whats the reason for this. How can i rectify this. Can call get disconnected due to this. Please suggest..... Help required immediately.