Function Json.toString
Returns the JSON object as a string.
string toString() @trusted const;
void toString
(
scope @safe void delegate(scope const(char)[]) sink,
std .format .spec .FormatSpec!(char) fmt
) @trusted;
void toString
(
scope void delegate(scope const(char)[]) sink,
std .format .spec .FormatSpec!(char) fmt
);
deprecated void toString
(
scope @safe void delegate(const(char)[]) sink,
std .format .spec .FormatSpec!(char) fmt
) @trusted;
void toString
(
scope void delegate(const(char)[]) sink,
std .format .spec .FormatSpec!(char) fmt
);
For large JSON values use writeJsonString instead as this function will store the whole string in memory, whereas writeJsonString writes it out bit for bit.
See Also
writeJsonString, toPrettyString