I'm an aspiring Java programmer looking to use JSON in a project. I was following a programming tutorial (from a book) which asked me to import JSON into my project by using the following line:
import com.google.appengine.repackaged.org.json.JSONArray;
But this produced an error, so I replaced it with this line:
import org.json.JSONArray;
This also produces a (different) error:
The import org.json cannot be resolved
I think the problem is that I don't actually have the JSON library in my Eclipse workspace. How can I do this, so I can use the JSONArray? I found the website for JSON, but am not sure what to download or how or where to install it:
http://json.org/java/
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…