Added constructor to the Emitter with a stream, so you can write directly to a stream instead of our temp

This commit is contained in:
Jesse Beder
2012-05-25 18:22:33 -05:00
parent e6d4a915dc
commit 2ffdc5b4d1
5 changed files with 32 additions and 11 deletions
+2 -1
View File
@@ -25,6 +25,7 @@ namespace YAML
{
public:
Emitter();
explicit Emitter(std::ostream& stream);
~Emitter();
// output
@@ -114,8 +115,8 @@ namespace YAML
bool CanEmitNewline() const;
private:
ostream_wrapper m_stream;
std::auto_ptr<EmitterState> m_pState;
ostream_wrapper m_stream;
};
template <typename T>