title: NoClassDefFoundError exception after having created jar file
body: <p>I have created a jar file including inside it some packages and a pair of file. This class file uses another package that I hadn't include in the jar file - I think that's the reason I get this exception:</p>
  
  <pre><code>Exception in thread "main" java.lang.NoClassDefFoundError: JigMonitorGUI (wrong name: org/w3c/jigmonitor/JigMonitorGUI)
  </code></pre>
  
  <p>How can I resolve this problem?</p>
  
  <p>EDIT</p>
  
  <p>the whole stacktrace:</p>
  
  <pre><code>Exception in thread "main" java.lang.NoClassDefFoundError: JigMonitorGUI (wrong name:  org/w3c/jigmonitor/JigMonitorGUI)
  at java.lang.ClassLoader.defineClass1(Native Method)
  at java.lang.ClassLoader.defineClass(ClassLoader.java:791)
  at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
  at java.net.URLClassLoader.defineClass(URLClassLoader.java:449)
  at java.net.URLClassLoader.access$100(URLClassLoader.java:71)
  at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
  at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
  at java.security.AccessController.doPrivileged(Native Method)
  at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
  at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
  at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
  at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
  at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:480)
  </code></pre>