6#include <bond/core/config.h>
19template<u
int16_t Size,
typename Allocator = std::allocator<
char> >
20class basic_string_stream
26 buffer.push_back(
'\0');
29 explicit basic_string_stream(
const Allocator& allocator)
33 buffer.push_back(
'\0');
36 basic_string_stream& operator<<(
const char* str)
46 template<
typename T,
typename A>
47 basic_string_stream& operator<<(
const std::basic_string<char, T, A>& str)
49 write(str.begin(), str.end());
53 basic_string_stream& operator<<(
char value)
60 basic_string_stream& operator<<(
const T& value)
62 return *
this << std::to_string(value);
65 std::string str()
const
70 const char* content()
const
79 buffer.push_back(
'\0');
83 void write(I begin, I end)
85 for ( ; begin != end; ++begin)
91 std::vector<char, Allocator> buffer;
94typedef basic_string_stream<1024> string_stream;
namespace bond
Definition: apply.h:17