MCPcopy Create free account
hub / github.com/ValveSoftware/openvr / BuiltStyledStreamWriter

Class BuiltStyledStreamWriter

src/jsoncpp.cpp:4873–4911  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4871};
4872
4873struct BuiltStyledStreamWriter : public StreamWriter
4874{
4875 BuiltStyledStreamWriter(
4876 std::string const& indentation,
4877 CommentStyle::Enum cs,
4878 std::string const& colonSymbol,
4879 std::string const& nullSymbol,
4880 std::string const& endingLineFeedSymbol,
4881 bool useSpecialFloats,
4882 unsigned int precision);
4883 int write(Value const& root, std::ostream* sout);
4884private:
4885 void writeValue(Value const& value);
4886 void writeArrayValue(Value const& value);
4887 bool isMultineArray(Value const& value);
4888 void pushValue(std::string const& value);
4889 void writeIndent();
4890 void writeWithIndent(std::string const& value);
4891 void indent();
4892 void unindent();
4893 void writeCommentBeforeValue(Value const& root);
4894 void writeCommentAfterValueOnSameLine(Value const& root);
4895 static bool hasCommentForValue(const Value& value);
4896
4897 typedef std::vector<std::string> ChildValues;
4898
4899 ChildValues childValues_;
4900 std::string indentString_;
4901 int rightMargin_;
4902 std::string indentation_;
4903 CommentStyle::Enum cs_;
4904 std::string colonSymbol_;
4905 std::string nullSymbol_;
4906 std::string endingLineFeedSymbol_;
4907 bool addChildValues_ : 1;
4908 bool indented_ : 1;
4909 bool useSpecialFloats_ : 1;
4910 unsigned int precision_;
4911};
4912BuiltStyledStreamWriter::BuiltStyledStreamWriter(
4913 std::string const& indentation,
4914 CommentStyle::Enum cs,

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected