Class JsonPrinter
In: lib/neo4jr-social/json_printer.rb
Parent: Object

Methods

new   render   render_html  

Constants

ESCAPED_CHARS = { "\010" => '\b', "\f" => '\f', "\n" => '\n', "\r" => '\r', "\t" => '\t', '"' => '\"', '\\' => '\\\\', '>' => '\u003E', '<' => '\u003C', '&' => '\u0026'}   Special JSON character escape cases.

Attributes

buf  [R] 
indent  [R] 

Public Class methods

Execute the JSON rendering of obj, storing the result in the buf.

Arguments

obj<Object>:The object to be rendered into JSON. This object and all of its associated objects must be either nil, true, false, a String, a Symbol, a Numeric, an Array, or a Hash.

Returns

<String>:The pretty-printed JSON ecoding of the given obj. This string can be parsed by any compliant JSON parser without modification.

Examples

See JsonPrinter docs.

[Validate]