yajl.encoder

Yajl Encoder

Members

Structs

Encoder
struct Encoder

Encoder provides the method for serializing a D object into JSON format.

Examples

Encoder encoder;
assert(encoder.encode(["foo":"bar"] == `{"foo":"bar"}`));

with option:

Encoder.Option opt;
opt.beautify = true;
opt.indentString = "  "; 
Encoder encoder = Encoder(opt);
assert(encoder.encode(["foo":"bar"] ==
`{
   "foo": "bar"
}
`));

See Also

Meta

License

<a href="http://www.boost.org/LICENSE_1_0.txt">Boost License 1.0</a>.

Authors

Masahiro Nakagawa