Package com.github.openjson
Class JSON
- java.lang.Object
-
- com.github.openjson.JSON
-
class JSON extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description JSON()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description (package private) static double
checkDouble(double d)
Returns the input if it is a JSON-permissible value; throws otherwise.(package private) static java.lang.Boolean
toBoolean(java.lang.Object value)
(package private) static java.lang.Double
toDouble(java.lang.Object value)
(package private) static java.lang.Integer
toInteger(java.lang.Object value)
(package private) static java.lang.Long
toLong(java.lang.Object value)
(package private) static java.lang.String
toString(java.lang.Object value)
static JSONException
typeMismatch(java.lang.Object indexOrName, java.lang.Object actual, java.lang.String requiredType)
static JSONException
typeMismatch(java.lang.Object actual, java.lang.String requiredType)
-
-
-
Method Detail
-
checkDouble
static double checkDouble(double d) throws JSONException
Returns the input if it is a JSON-permissible value; throws otherwise.- Throws:
JSONException
-
toBoolean
static java.lang.Boolean toBoolean(java.lang.Object value)
-
toDouble
static java.lang.Double toDouble(java.lang.Object value)
-
toInteger
static java.lang.Integer toInteger(java.lang.Object value)
-
toLong
static java.lang.Long toLong(java.lang.Object value)
-
toString
static java.lang.String toString(java.lang.Object value)
-
typeMismatch
public static JSONException typeMismatch(java.lang.Object indexOrName, java.lang.Object actual, java.lang.String requiredType) throws JSONException
- Throws:
JSONException
-
typeMismatch
public static JSONException typeMismatch(java.lang.Object actual, java.lang.String requiredType) throws JSONException
- Throws:
JSONException
-
-