JSONValue
A JSON value represents an object, array, or fragment.
This type does not represent the null
value in JSON. Use Optional<JSONValue>
wherever null
is accepted.
-
A string.
-
A floating-point number.
JSON does not distinguish numeric types of different precisions. If you need integer precision, cast the value to an
Int
. -
A Boolean value.
-
A heterogeneous array of JSON values and
null
values. -
An object containing JSON values and
null
values keyed by strings. -
Initializes a JSON value representing the given string.
-
-
-
This branch must happen after the
NSNumber
branch to avoid convertingNSNumber
instances with values 0 and 1 but of objCType != ‘c’ toBool
sinceas? Bool
can succeed when the NSNumber’s value is 0 or 1 even when its objCType is not ‘c’. -
-
-
-
-
-
-
-
-
-
-