emacs 24.3.1 Fedora 20 jdk1.7.0_45
I created a java project using emacs and have the following project files and classpath:
.project
<?xml version="1.0" encoding="UTF-8"?> <projectDescription> <name>snaprequest</name> <comment></comment> <projects> </projects> <buildSpec> <buildCommand> <name>org.eclipse.jdt.core.javabuilder</name> <arguments> </arguments> </buildCommand> </buildSpec> <natures> <nature>org.eclipse.jdt.core.javanature</nature> </natures> </projectDescription>
.classpath
<?xml version="1.0" encoding="UTF-8"?> <classpath> <classpathentry kind="src" path="src"/> <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/> <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/> <classpathentry kind="output" path="bin"/> </classpath>
I have this version
In my java program, I want to use JSONObject, so I tried to import the following:
import org.json.JSONObject;
And when I try to compile on the command line, I get this error:
error: package org.json does not exist import org.json.JSONObject;
I know that I need to add something to my classpath so that it can find jar files, but I'm not sure how to do this?
Thanks so much for any suggestions,
source share