I am trying to use JSONObject in my Servlet class using Netbeans , I imported several versions of json simple jar , but accumulate method is not there ,infact none of the json methods are there when i try to use autocomplete for methods on json object. Any Reasons ?
Asked
Active
Viewed 156 times
0
-
what makes you think it should be there? – njzk2 May 05 '15 at 18:27
-
sorry ? isnt it in the json library ? – devcodes May 05 '15 at 18:31
-
http://www.json.org/javadoc/org/json/JSONObject.html the very first method – devcodes May 05 '15 at 18:43
-
that's the doc for that library: https://github.com/douglascrockford/JSON-java (there are plenty others) – njzk2 May 05 '15 at 19:05
1 Answers
0
Not really an answer, but, what makes you think there is such a method? As you can see on the screenshot, neither JSONObject nor any other class of this library have this method.
Following the Javadoc link you've provided it appears that you're using json-simple library but following Javadoc for org.json library.
I haven't found ready-to-use jar-file for this library so I builded it by myself from GitHub sources. Here is the link on Google Drive. But, take notice, I've only made sure there's no errors during compilation, I haven't tested if it works properly so it's totally up to you. Just import this lib using org.json
and try to use it.

Mugi4ok
- 285
- 2
- 5
- 15
-
@user3820753, I've updated the answer adding compiled lib this Javadoc belongs to, give it a try. – Mugi4ok May 06 '15 at 09:40
-
-
@user3820753 You're welcome. Maybe it'll make use for someone else still. – Mugi4ok May 07 '15 at 11:39