public class JSONException
extends java.lang.Exception
NaNs
or infinities
.
Although this is a checked exception, it is rarely recoverable. Most callers should simply wrap this exception in an unchecked exception and rethrow:
public JSONArray toJSONObject() { try { JSONObject result = new JSONObject(); ... } catch (JSONException e) { throw new RuntimeException(e); } }
Constructor and Description |
---|
JSONException(java.lang.String s) |
Copyright © 2013 The Android Open Source Project. All Rights Reserved.