1
0
Fork 0
mirror of https://github.com/ethauvin/JSON-java.git synced 2025-06-17 07:50:52 -07:00

Merge remote-tracking branch 'upstream/master' into EnumCleanup

This commit is contained in:
John J. Aylward 2016-08-15 10:25:27 -04:00
commit 349a209df3
2 changed files with 7 additions and 5 deletions

View file

@ -78,7 +78,7 @@ import java.util.Map;
* </ul> * </ul>
* *
* @author JSON.org * @author JSON.org
* @version 2016-05-20 * @version 2016-08/15
*/ */
public class JSONArray implements Iterable<Object> { public class JSONArray implements Iterable<Object> {
@ -961,7 +961,7 @@ public class JSONArray implements Iterable<Object> {
} }
/** /**
* Creates a JSONPointer using an intialization string and tries to * Creates a JSONPointer using an initialization string and tries to
* match it to an item within this JSONArray. For example, given a * match it to an item within this JSONArray. For example, given a
* JSONArray initialized with this document: * JSONArray initialized with this document:
* <pre> * <pre>

View file

@ -93,7 +93,7 @@ import java.util.Set;
* </ul> * </ul>
* *
* @author JSON.org * @author JSON.org
* @version 2016-05-20 * @version 2016-08-15
*/ */
public class JSONObject { public class JSONObject {
/** /**
@ -132,6 +132,7 @@ public class JSONObject {
* *
* @return The string "null". * @return The string "null".
*/ */
@Override
public String toString() { public String toString() {
return "null"; return "null";
} }
@ -1621,6 +1622,7 @@ public class JSONObject {
* brace)</small> and ending with <code>}</code>&nbsp;<small>(right * brace)</small> and ending with <code>}</code>&nbsp;<small>(right
* brace)</small>. * brace)</small>.
*/ */
@Override
public String toString() { public String toString() {
try { try {
return this.toString(0); return this.toString(0);
@ -1885,13 +1887,13 @@ public class JSONObject {
} }
/** /**
* Returns a java.util.Map containing all of the entrys in this object. * Returns a java.util.Map containing all of the entries in this object.
* If an entry in the object is a JSONArray or JSONObject it will also * If an entry in the object is a JSONArray or JSONObject it will also
* be converted. * be converted.
* <p> * <p>
* Warning: This method assumes that the data structure is acyclical. * Warning: This method assumes that the data structure is acyclical.
* *
* @return a java.util.Map containing the entrys of this object * @return a java.util.Map containing the entries of this object
*/ */
public Map<String, Object> toMap() { public Map<String, Object> toMap() {
Map<String, Object> results = new HashMap<String, Object>(); Map<String, Object> results = new HashMap<String, Object>();