diff --git a/JSONObject.java b/JSONObject.java
index 1ce25401f..01e7d5705 100644
--- a/JSONObject.java
+++ b/JSONObject.java
@@ -34,7 +34,7 @@ of this software and associated documentation files (the "Software"), to deal
import java.math.BigInteger;
import java.util.Collection;
import java.util.Enumeration;
-import java.util.HashMap;
+import java.util.LinkedHashMap;
import java.util.Iterator;
import java.util.Locale;
import java.util.Map;
@@ -43,7 +43,7 @@ of this software and associated documentation files (the "Software"), to deal
import java.util.Set;
/**
- * A JSONObject is an unordered collection of name/value pairs. Its external
+ * A JSONObject is an collection of name/value pairs. Its external
* form is a string wrapped in curly braces with colons between the names and
* values, and commas between the values and names. The internal form is an
* object having get and opt methods for accessing
@@ -154,7 +154,7 @@ public String toString() {
* Construct an empty JSONObject.
*/
public JSONObject() {
- this.map = new HashMap();
+ this.map = new LinkedHashMap();
}
/**
@@ -240,7 +240,7 @@ public JSONObject(JSONTokener x) throws JSONException {
* the JSONObject.
*/
public JSONObject(Map, ?> map) {
- this.map = new HashMap();
+ this.map = new LinkedHashMap();
if (map != null) {
for (final Entry, ?> e : map.entrySet()) {
final Object value = e.getValue();