I am trying to build a program using the Processing library in eclipse. The process should be relatively straightforward but I cannot compile even an empty processing program. I think the problem may be something to do with my classpaths, I'm not sure. I have attempted to import the processing library and write the simple program several times on both Eclipse and IntelliJ with no luck.
This is the program:
import processing.core.PApplet;
public class Processing extends PApplet {
public static void main(String[] args) {
PApplet.main("Processing", args);
}
}
These are the errors I get:
java.lang.NoClassDefFoundError: com/apple/eawt/QuitHandler
at java.base/java.lang.Class.getDeclaredMethods0(Native Method)
at java.base/java.lang.Class.privateGetDeclaredMethods(Class.java:3139)
at java.base/java.lang.Class.getMethodsRecursive(Class.java:3280)
at java.base/java.lang.Class.getMethod0(Class.java:3266)
at java.base/java.lang.Class.getMethod(Class.java:2063)
at processing.core.PApplet.runSketch(PApplet.java:10716)
at processing.core.PApplet.main(PApplet.java:10513)
at Processing.main(Processing.java:6)
Caused by: java.lang.ClassNotFoundException: com.apple.eawt.QuitHandler
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:582)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:185)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:496)
... 8 more
I've uninstalled the java JDK and reinstalled it but it did not make a difference. Any help on this issue would be greatly appreciated, I cant seem to find anyone else online with the exact same problem.