prettywriter.h Source File#
prettywriter.h
Go to the documentation of this file.
void PrettyPrefix(Type type)
Simpler but slower overload.
Definition prettywriter.h:276
PrettyFormatOptions formatOptions_
Simpler but slower overload.
Definition prettywriter.h:340
bool Key(const Ch *str, SizeType length, bool copy=false)
Definition prettywriter.h:188
bool RawNumber(const Ch *str, SizeType length, bool copy=false)
Definition prettywriter.h:158
bool RawValue(const Ch *json, size_t length, Type type)
Write a raw JSON value.
Definition prettywriter.h:268
PrettyWriter(StackAllocator *allocator=0, size_t levelDepth=Base::kDefaultLevelDepth)
Definition prettywriter.h:75
Writer< OutputStream, SourceEncoding, TargetEncoding, StackAllocator, writeFlags > Base
Definition prettywriter.h:57
void WriteIndent()
Simpler but slower overload.
Definition prettywriter.h:331
unsigned indentCharCount_
Simpler but slower overload.
Definition prettywriter.h:339
bool String(const Ch *str)
Simpler but slower overload.
Definition prettywriter.h:255
PrettyWriter(OutputStream &os, StackAllocator *allocator=0, size_t levelDepth=Base::kDefaultLevelDepth)
Constructor.
Definition prettywriter.h:65
PrettyWriter & SetFormatOptions(PrettyFormatOptions options)
Set pretty writer formatting options.
Definition prettywriter.h:111
PrettyWriter & SetIndent(Ch indentChar, unsigned indentCharCount)
Set custom indentation.
Definition prettywriter.h:99
bool String(const Ch *str, SizeType length, bool copy=false)
Definition prettywriter.h:166
bool WriteUint(unsigned u)
Definition writer.h:389
bool WriteInt(int i)
Definition writer.h:379
OutputStream * os_
Definition writer.h:630
bool WriteStartArray()
Definition writer.h:570
bool WriteBool(bool b)
Definition writer.h:357
bool WriteNull()
Definition writer.h:347
bool WriteEndObject()
Definition writer.h:565
Writer< OutputStream, SourceEncoding, TargetEncoding, StackAllocator, writeFlags >::WriteStartObject
bool WriteStartObject()
Definition writer.h:560
void Flush()
Definition writer.h:334
bool WriteRawValue(const Ch *json, size_t length)
Definition writer.h:581
static const size_t kDefaultLevelDepth
Definition writer.h:336
internal::Stack< StackAllocator > level_stack_
Definition writer.h:631
bool WriteInt64(int64_t i64)
Definition writer.h:399
bool WriteEndArray()
Definition writer.h:575
SourceEncoding::Ch Ch
Definition writer.h:101
bool WriteString(const Ch *str, SizeType length)
Definition writer.h:468
bool WriteUint64(uint64_t u64)
Definition writer.h:409
bool EndValue(bool ret)
Definition writer.h:623
bool WriteDouble(double d)
Definition writer.h:419
Writer(OutputStream &os, CrtAllocator *stackAllocator=0, size_t levelDepth=kDefaultLevelDepth)
Definition writer.h:110
bool hasRoot_
Definition writer.h:633
__device__ void copy(const SrcTensorType &src_tensor, DstTensorType &dst_tensor)
Perform optimized copy between two tensors partitions (threadwise copy). Tensors must have the same s...
Definition copy.hpp:36
void PutN(FileWriteStream &stream, char c, size_t n)
Implement specialized version of PutN() with memset() for better performance.
Definition filewritestream.h:124
#define RAPIDJSON_NAMESPACE_BEGIN
provide custom rapidjson namespace (opening expression)
Definition rapidjson.h:121
#define RAPIDJSON_NAMESPACE_END
provide custom rapidjson namespace (closing expression)
Definition rapidjson.h:124
SizeType StrLen(const Ch *s)
Custom strlen() which works on different character types.
Definition strfunc.h:32
STL namespace.
PrettyFormatOptions
Combination of PrettyWriter format flags.
Definition prettywriter.h:36
@ kFormatSingleLineArray
Format arrays on a single line.
Definition prettywriter.h:38
RAPIDJSON_NAMESPACE_BEGIN typedef unsigned SizeType
Size type (for string lengths, array sizes, etc.).
Definition rapidjson.h:429