Unhandled JSONException Type
You need to wrap your code in a try-catch block. This is your warning.
JSONObject login = new JSONObject();
try {
login.put("Key1", "Value1");
}
catch (JSONException e) {... }
Are they the equivalent way to create an object with a key, a pair value. Which is the preferred way when creating the object that is needed to send to the service.
JSONObject.put()cancels JSONException and Map.put()no.
-, .
JSON - , , , .
Map ( ) , , KeySet() Map String (, StringBuilder), , JSON.
, " " , JSON .