7 #ifndef BIL_XMLWRITER_HPP
8 #define BIL_XMLWRITER_HPP
41 explicit XMLWriter(std::ostream& os,
size_t baseIndent = 0,
size_t levelIndent = 2);
54 void beginElement(
const std::string& name,
bool newLine =
true);
75 void addAttribute(
const std::string& name,
const std::string& value);
86 void addAttribute(
const std::string& name,
unsigned value);
98 void addData(
const std::string& data,
bool newLine =
true);
114 size_t depth()
const;
129 std::ostream& m_outputStream;
131 std::stack<std::string> m_elementStack;
132 bool m_insideOpeningTag;
134 size_t m_levelIndent;
135 std::string m_lineIndentString;