15 #ifndef RAPIDJSON_STRINGBUFFER_H_ 16 #define RAPIDJSON_STRINGBUFFER_H_ 21 #if RAPIDJSON_HAS_CXX11_RVALUE_REFS 27 #if defined(__clang__) 29 RAPIDJSON_DIAG_OFF(
c++98-compat)
40 template <
typename Encoding,
typename Allocator = CrtAllocator>
43 typedef typename Encoding::Ch
Ch;
47 #if RAPIDJSON_HAS_CXX11_RVALUE_REFS 51 stack_ = std::move(rhs.stack_);
63 *
stack_.template Push<Ch>() =
'\0';
65 stack_.template Pop<Ch>(1);
75 *
stack_.template Push<Ch>() =
'\0';
76 stack_.template Pop<Ch>(1);
78 return stack_.template Bottom<Ch>();
95 template<
typename Encoding,
typename Allocator>
100 template<
typename Encoding,
typename Allocator>
113 #if defined(__clang__) 117 #endif // RAPIDJSON_STRINGBUFFER_H_ void PutUnsafe(GenericStringBuffer< Encoding, Allocator > &stream, typename Encoding::Ch c)
Definition: stringbuffer.h:101
void PutN(GenericStringBuffer< UTF8<> > &stream, char c, size_t n)
Implement specialized version of PutN() with memset() for better performance.
Definition: stringbuffer.h:107
A type-unsafe stack for storing different types of data.
Definition: stack.h:36
void ShrinkToFit()
Definition: stringbuffer.h:61
void Clear()
Definition: stringbuffer.h:60
internal::Stack< Allocator > stack_
Definition: stringbuffer.h:84
void Flush()
Definition: stringbuffer.h:58
void PutUnsafe(Ch c)
Definition: stringbuffer.h:57
GenericStringBuffer(Allocator *allocator=0, size_t capacity=kDefaultCapacity)
Definition: stringbuffer.h:45
#define RAPIDJSON_NAMESPACE_END
provide custom rapidjson namespace (closing expression)
Definition: rapidjson.h:119
const GLubyte * c
Definition: glext.h:9812
GLuint GLuint GLsizei count
Definition: glext.h:6292
void Put(Ch c)
Definition: stringbuffer.h:56
GenericStringBuffer< UTF8<> > StringBuffer
String buffer with UTF8 encoding.
Definition: stringbuffer.h:93
void Pop(size_t count)
Definition: stringbuffer.h:71
Encoding::Ch Ch
Definition: stringbuffer.h:43
size_t GetSize() const
Definition: stringbuffer.h:81
Ch * PushUnsafe(size_t count)
Definition: stringbuffer.h:70
static const size_t kDefaultCapacity
Definition: stringbuffer.h:83
const Ch * GetString() const
Definition: stringbuffer.h:73
void Reserve(size_t count)
Definition: stringbuffer.h:68
GenericStringBuffer & operator=(const GenericStringBuffer &)
#define RAPIDJSON_NAMESPACE_BEGIN
provide custom rapidjson namespace (opening expression)
Definition: rapidjson.h:116
GLuint GLuint stream
Definition: glext.h:8189
void PutReserve(GenericStringBuffer< Encoding, Allocator > &stream, size_t count)
Definition: stringbuffer.h:96
Ch * Push(size_t count)
Definition: stringbuffer.h:69
UTF-8 encoding.
Definition: encodings.h:96
void * memset(void *b, int c, size_t len)
Definition: string.c:7
Represents an in-memory output stream.
Definition: fwd.h:59
GLdouble n
Definition: glext.h:8396