1
0
Fork 0
mirror of https://github.com/ethauvin/JSON-java.git synced 2025-06-17 07:50:52 -07:00
A reference implementation of a JSON package in Java.
Find a file
Sean Leary 09b6af4712 Merge pull request #160 from johnjaylward/FixXMLNPE
Fixes possible NullPointerException in XML.toString(object, tagName)
2015-10-18 10:21:36 -05:00
CDL.java s/covert/convert/ 2015-05-01 12:52:23 -05:00
Cookie.java Java 1.8. 2014-05-05 15:09:32 -07:00
CookieList.java Java 1.8. 2014-05-05 15:09:32 -07:00
HTTP.java Java 1.8. 2014-05-05 15:09:32 -07:00
HTTPTokener.java Java 1.8. 2014-05-05 15:09:32 -07:00
JSONArray.java fix edit dates for enum support 2015-07-22 20:18:30 -05:00
JSONException.java Java 1.8. 2014-05-05 15:09:32 -07:00
JSONML.java fix toString(JSONArray) to emit object.toString() values 2015-04-19 17:53:40 -05:00
JSONObject.java fix edit dates for enum support 2015-07-22 20:18:30 -05:00
JSONString.java whitespace 2012-11-13 14:56:55 -08:00
JSONStringer.java first commit 2010-12-21 10:51:19 -08:00
JSONTokener.java Java 1.8. 2014-05-05 15:09:32 -07:00
JSONWriter.java Java 1.8. 2014-05-05 15:09:32 -07:00
Property.java Replaced tab chars, updated versions 2015-05-05 20:11:28 -05:00
README Update README 2015-07-29 19:50:14 -05:00
XML.java updates file dates 2015-10-14 00:48:01 -04:00
XMLTokener.java Java 1.8. 2014-05-05 15:09:32 -07:00

JSON in Java [package org.json]

JSON is a light-weight, language independent, data interchange format.
See http://www.JSON.org/

The files in this package implement JSON encoders/decoders in Java.
It also includes the capability to convert between JSON and XML, HTTP
headers, Cookies, and CDL.

This is a reference implementation. There is a large number of JSON packages
in Java. Perhaps someday the Java community will standardize on one. Until
then, choose carefully.

The license includes this restriction: "The software shall be used for good,
not evil." If your conscience cannot live with that, then choose a different
package.

The package compiles on Java 1.8.


JSONObject.java: The JSONObject can parse text from a String or a JSONTokener
to produce a map-like object. The object provides methods for manipulating its
contents, and for producing a JSON compliant object serialization.

JSONArray.java: The JSONObject can parse text from a String or a JSONTokener
to produce a vector-like object. The object provides methods for manipulating
its contents, and for producing a JSON compliant array serialization.

JSONTokener.java: The JSONTokener breaks a text into a sequence of individual
tokens. It can be constructed from a String, Reader, or InputStream.

JSONException.java: The JSONException is the standard exception type thrown
by this package.


JSONString.java: The JSONString interface requires a toJSONString method,
allowing an object to provide its own serialization.

JSONStringer.java: The JSONStringer provides a convenient facility for
building JSON strings.

JSONWriter.java: The JSONWriter provides a convenient facility for building
JSON text through a writer.


CDL.java: CDL provides support for converting between JSON and comma
delimited lists.

Cookie.java: Cookie provides support for converting between JSON and cookies.

CookieList.java: CookieList provides support for converting between JSON and
cookie lists.

HTTP.java: HTTP provides support for converting between JSON and HTTP headers.

HTTPTokener.java: HTTPTokener extends JSONTokener for parsing HTTP headers.

XML.java: XML provides support for converting between JSON and XML.

JSONML.java: JSONML provides support for converting between JSONML and XML.

XMLTokener.java: XMLTokener extends JSONTokener for parsing XML text.

Unit tests are maintained in a separate project. Contributing developers can test JSON-java pull requests with the code in this project: https://github.com/stleary/JSON-Java-unit-test