util::json::indent (public)

 util::json::indent [ -simplify ] json

Defined in packages/acs-tcl/tcl/json-procs.tcl

Indent a JSON string to make it more easily digestable by the human mind. This works best (by far) if the JSON string doesn't already contain newlines (as will be true of JSON strings generated by util::json::gen).

Switches:
-simplify (optional, boolean)
If true, remove all fields that don't contribute to the structure of the object/array combination being described by the string.
Parameters:
json (required)
The string to indent
Returns:
The beautifully indented, and optionally simplified, string

Partial Call Graph (max 5 caller/called nodes):
%3

Testcases:
No testcase defined.
[ show source ]
Show another procedure: