The OpenD Programming Language

JSONValue.array

Value getter/setter for JSONType.array.

  1. inout(JSONValue[]) array [@property getter]
    struct JSONValue
    @property ref scope return inout pure @system
    inout(JSONValue[])
    array
    ()
  2. JSONValue[] array [@property setter]

Throws

JSONException for read access if type is not JSONType.array. Note: This is @system because of the following pattern:

auto a = &(json.array());
json.uinteger = 0;  // overwrite array pointer
(*a)[0] = "world";  // segmentation fault

Meta