mirror of
https://github.com/open-source-parsers/jsoncpp.git
synced 2025-10-11 02:00:46 +02:00
mv CommentStyle to .cpp
This commit is contained in:
@@ -92,13 +92,13 @@ features without losing binary-compatibility.
|
||||
\code
|
||||
// For convenience, use `writeString()` with a specialized builder.
|
||||
Json::StreamWriterBuilder wbuilder;
|
||||
wbuilder.settings_["indentation"] = "\t";
|
||||
wbuilder.settings_["indentation"] = "\t"; // simple Json::Value
|
||||
std::string document = Json::writeString(wbuilder, root);
|
||||
|
||||
// Here, using a specialized Builder, we discard comments and
|
||||
// record errors as we parse.
|
||||
Json::CharReaderBuilder rbuilder;
|
||||
rbuilder.settings_["collectComments"] = false;
|
||||
rbuilder.settings_["collectComments"] = false; // simple Json::Value
|
||||
std::string errs;
|
||||
bool ok = Json::parseFromStream(rbuilder, std::cin, &root, &errs);
|
||||
\endcode
|
||||
|
Reference in New Issue
Block a user