Json.read

Reads a number off the JSON text.

If you ask for an unsigned value, no minus sign will be accepted in the JSON, otherwise all features of JSON numbers will be available. In particular large integers can be given in scientific notation.

  1. string read(bool allowNull)
  2. T read()
  3. N read()
    struct Json(uint vl = validateUsed, bool validateUtf8 = vl > trustedSource)
    N
    read
    (
    N
    )
    ()
    if (
    isNumeric!N &&
    !is(N == enum)
    )
    if (
    vl > trustedSource ||
    !validateUtf8
    )
  4. T read()
  5. T read()
  6. T read()
  7. T read()
  8. T read()
  9. bool read()

Parameters

N

Built-in numerical type that should be returned.

Return Value

Type: N

The parsed number.

Throws

JSONException, on invalid JSON or integer overflow.

Meta