MyGUI 3.4.3
MyGUI_LogStream.h
Go to the documentation of this file.
1/*
2 * This source file is part of MyGUI. For the latest info, see http://mygui.info/
3 * Distributed under the MIT License
4 * (See accompanying file COPYING.MIT or copy at http://opensource.org/licenses/MIT)
5 */
6
7#ifndef MYGUI_LOG_STREAM_H_
8#define MYGUI_LOG_STREAM_H_
9
10#include "MyGUI_Prerequest.h"
11#include <cstring>
12#include <sstream>
13
14namespace MyGUI
15{
16
18 {
19 public:
20 struct End
21 {
22 };
23
24 public:
25 std::string operator<<(const End& /*_endl*/)
26 {
27 return mStream.str();
28 }
29
30 template<typename T>
31 LogStream& operator<<(const T& _value)
32 {
33 mStream << _value;
34 return *this;
35 }
36
37 private:
38 std::ostringstream mStream;
39 };
40
41} // namespace MyGUI
42
43#endif // MYGUI_LOG_STREAM_H_
#define MYGUI_EXPORT
std::string operator<<(const End &)
LogStream & operator<<(const T &_value)