We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Better a self-explanatory example
Collection collectionStrings = new ArrayList(); collectionStrings.add("a"); collectionStrings.add("b");
String[] arrayStrings = new String[]{"x", "y"};
JSONObject jo = new JSONObject(); jo.put("collection", collectionStrings); jo.put("array", arrayStrings);
System.out.println(jo);
@@ OUTPUT @@ {"collection":["a","b"],"array":"[Ljava.lang.String;@7106e68e"}
From my point of view, JSONObject should handle properly the array and print ["x", "y"] instead of calling the method toString() of the array.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Better a self-explanatory example
Collection collectionStrings = new ArrayList();
collectionStrings.add("a");
collectionStrings.add("b");
String[] arrayStrings = new String[]{"x", "y"};
JSONObject jo = new JSONObject();
jo.put("collection", collectionStrings);
jo.put("array", arrayStrings);
System.out.println(jo);
@@ OUTPUT @@
{"collection":["a","b"],"array":"[Ljava.lang.String;@7106e68e"}
From my point of view, JSONObject should handle properly the array and print ["x", "y"] instead of calling the method toString() of the array.
The text was updated successfully, but these errors were encountered: