| JsonCpp project page | JsonCpp home page |
Build a StreamWriter implementation. More...
#include <json/writer.h>
Inheritance diagram for Json::StreamWriterBuilder:
Collaboration diagram for Json::StreamWriterBuilder:Public Member Functions | |
| StreamWriterBuilder () | |
| ~StreamWriterBuilder () | |
| StreamWriter * | newStreamWriter () const |
| bool | validate (Json::Value *invalid) const |
| Value & | operator[] (std::string key) |
| A simple way to update a specific setting. More... | |
Public Member Functions inherited from Json::StreamWriter::Factory | |
| virtual | ~Factory () |
Static Public Member Functions | |
| static void | setDefaults (Json::Value *settings) |
| Called by ctor, but you can use this to reset settings_. More... | |
Public Attributes | |
| Json::Value | settings_ |
| Configuration of this builder. More... | |
Build a StreamWriter implementation.
Usage:
| Json::StreamWriterBuilder::StreamWriterBuilder | ( | ) |
Definition at line 1128 of file json_writer.cpp.
| Json::StreamWriterBuilder::~StreamWriterBuilder | ( | ) |
Definition at line 1132 of file json_writer.cpp.
|
virtual |
| std::exception | if something goes wrong (e.g. invalid settings) |
Implements Json::StreamWriter::Factory.
Definition at line 1134 of file json_writer.cpp.
References JSONCPP_STRING.
Referenced by Json::operator<<().
Here is the caller graph for this function:| Value & Json::StreamWriterBuilder::operator[] | ( | std::string | key | ) |
A simple way to update a specific setting.
Definition at line 1193 of file json_writer.cpp.
|
static |
Called by ctor, but you can use this to reset settings_.
[StreamWriterBuilderDefaults]
[StreamWriterBuilderDefaults]
Definition at line 1198 of file json_writer.cpp.
| bool Json::StreamWriterBuilder::validate | ( | Json::Value * | invalid | ) | const |
Definition at line 1176 of file json_writer.cpp.
References Json::getValidWriterKeys(), JSONCPP_STRING, and Json::Value::size().
| Json::Value Json::StreamWriterBuilder::settings_ |
Configuration of this builder.
Available settings (case-sensitive):
You can examine 'settings_` yourself to see the defaults. You can also write and read them just like any JSON Value.