Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在开发一个使用该org.json.JSONObject包的 Java 项目。但是,每当我在 eclipse 中使用它时,它都会说没有找到这样的包。但是,当我在 android 上开发时,即在 eclipse 中创建一个新的 Android 项目,我可以在不做任何事情的情况下使用它(不添加外部 JAR 和其他东西),所以我很确定所需的 JAR 在我的机器上。
org.json.JSONObject
但是,在我的整个文件系统中搜索“org.json”、“*json*jar”、“json*jar”并没有返回任何内容。
我不为 android 开发,但看起来该类是该 SDK for Android 的一部分。我不确定它是否是完全相同的类,但是 json.org 在这里有一个具有相同名称和包的类,或者您可以从这里的 Java 列表中选择一个不同的类来使用。