bes
Updated for version 3.20.6
|
A document for parsing JSON text as DOM. More...
#include <document.h>
Public Types | |
typedef Allocator | AllocatorType |
Allocator type from template parameter. More... | |
typedef Allocator | AllocatorType |
Allocator type from template parameter. More... | |
typedef Encoding::Ch | Ch |
Character type derived from Encoding. More... | |
typedef Encoding::Ch | Ch |
Character type derived from Encoding. More... | |
typedef GenericValue< Encoding, Allocator > | ValueType |
Value type of the document. More... | |
typedef GenericValue< Encoding, Allocator > | ValueType |
Value type of the document. More... | |
Public Member Functions | |
bool | Bool (bool b) |
bool | Bool (bool b) |
bool | Double (double d) |
bool | Double (double d) |
bool | EndArray (SizeType elementCount) |
bool | EndArray (SizeType elementCount) |
bool | EndObject (SizeType memberCount) |
bool | EndObject (SizeType memberCount) |
GenericDocument (Allocator *allocator=0, size_t stackCapacity=kDefaultStackCapacity, StackAllocator *stackAllocator=0) | |
Constructor. More... | |
GenericDocument (Allocator *allocator=0, size_t stackCapacity=kDefaultStackCapacity, StackAllocator *stackAllocator=0) | |
Constructor. More... | |
GenericDocument (Type type, Allocator *allocator=0, size_t stackCapacity=kDefaultStackCapacity, StackAllocator *stackAllocator=0) | |
Constructor. More... | |
GenericDocument (Type type, Allocator *allocator=0, size_t stackCapacity=kDefaultStackCapacity, StackAllocator *stackAllocator=0) | |
Constructor. More... | |
Allocator & | GetAllocator () |
Get the allocator of this document. More... | |
Allocator & | GetAllocator () |
Get the allocator of this document. More... | |
size_t | GetStackCapacity () const |
Get the capacity of stack in bytes. More... | |
size_t | GetStackCapacity () const |
Get the capacity of stack in bytes. More... | |
bool | Int (int i) |
bool | Int (int i) |
bool | Int64 (int64_t i) |
bool | Int64 (int64_t i) |
bool | Key (const Ch *str, SizeType length, bool copy) |
bool | Key (const Ch *str, SizeType length, bool copy) |
bool | Null () |
bool | Null () |
template<typename Generator > | |
GenericDocument & | Populate (Generator &g) |
Populate this document by a generator which produces SAX events. More... | |
template<typename Generator > | |
GenericDocument & | Populate (Generator &g) |
Populate this document by a generator which produces SAX events. More... | |
bool | RawNumber (const Ch *str, SizeType length, bool copy) |
bool | RawNumber (const Ch *str, SizeType length, bool copy) |
bool | StartArray () |
bool | StartArray () |
bool | StartObject () |
bool | StartObject () |
bool | String (const Ch *str, SizeType length, bool copy) |
bool | String (const Ch *str, SizeType length, bool copy) |
GenericDocument & | Swap (GenericDocument &rhs) RAPIDJSON_NOEXCEPT |
Exchange the contents of this document with those of another. More... | |
GenericDocument & | Swap (GenericDocument &rhs) RAPIDJSON_NOEXCEPT |
Exchange the contents of this document with those of another. More... | |
bool | Uint (unsigned i) |
bool | Uint (unsigned i) |
bool | Uint64 (uint64_t i) |
bool | Uint64 (uint64_t i) |
Parse from stream | |
template<unsigned parseFlags, typename SourceEncoding , typename InputStream > | |
GenericDocument & | ParseStream (InputStream &is) |
Parse JSON text from an input stream (with Encoding conversion) More... | |
template<unsigned parseFlags, typename InputStream > | |
GenericDocument & | ParseStream (InputStream &is) |
Parse JSON text from an input stream. More... | |
template<typename InputStream > | |
GenericDocument & | ParseStream (InputStream &is) |
Parse JSON text from an input stream (with kParseDefaultFlags) More... | |
template<unsigned parseFlags, typename SourceEncoding , typename InputStream > | |
GenericDocument & | ParseStream (InputStream &is) |
Parse JSON text from an input stream (with Encoding conversion) More... | |
template<unsigned parseFlags, typename InputStream > | |
GenericDocument & | ParseStream (InputStream &is) |
Parse JSON text from an input stream. More... | |
template<typename InputStream > | |
GenericDocument & | ParseStream (InputStream &is) |
Parse JSON text from an input stream (with kParseDefaultFlags) More... | |
Parse in-place from mutable string | |
template<unsigned parseFlags> | |
GenericDocument & | ParseInsitu (Ch *str) |
Parse JSON text from a mutable string. More... | |
GenericDocument & | ParseInsitu (Ch *str) |
Parse JSON text from a mutable string (with kParseDefaultFlags) More... | |
template<unsigned parseFlags> | |
GenericDocument & | ParseInsitu (Ch *str) |
Parse JSON text from a mutable string. More... | |
GenericDocument & | ParseInsitu (Ch *str) |
Parse JSON text from a mutable string (with kParseDefaultFlags) More... | |
Parse from read-only string | |
template<unsigned parseFlags, typename SourceEncoding > | |
GenericDocument & | Parse (const typename SourceEncoding::Ch *str) |
Parse JSON text from a read-only string (with Encoding conversion) More... | |
template<unsigned parseFlags> | |
GenericDocument & | Parse (const Ch *str) |
Parse JSON text from a read-only string. More... | |
GenericDocument & | Parse (const Ch *str) |
Parse JSON text from a read-only string (with kParseDefaultFlags) More... | |
template<unsigned parseFlags, typename SourceEncoding > | |
GenericDocument & | Parse (const typename SourceEncoding::Ch *str, size_t length) |
template<unsigned parseFlags> | |
GenericDocument & | Parse (const Ch *str, size_t length) |
GenericDocument & | Parse (const Ch *str, size_t length) |
template<unsigned parseFlags, typename SourceEncoding > | |
GenericDocument & | Parse (const typename SourceEncoding::Ch *str) |
Parse JSON text from a read-only string (with Encoding conversion) More... | |
template<unsigned parseFlags> | |
GenericDocument & | Parse (const Ch *str) |
Parse JSON text from a read-only string. More... | |
GenericDocument & | Parse (const Ch *str) |
Parse JSON text from a read-only string (with kParseDefaultFlags) More... | |
template<unsigned parseFlags, typename SourceEncoding > | |
GenericDocument & | Parse (const typename SourceEncoding::Ch *str, size_t length) |
template<unsigned parseFlags> | |
GenericDocument & | Parse (const Ch *str, size_t length) |
GenericDocument & | Parse (const Ch *str, size_t length) |
Handling parse errors | |
bool | HasParseError () const |
Whether a parse error has occured in the last parsing. More... | |
ParseErrorCode | GetParseError () const |
Get the ParseErrorCode of last parsing. More... | |
size_t | GetErrorOffset () const |
Get the position of last parsing error in input, 0 otherwise. More... | |
operator ParseResult () const | |
Implicit conversion to get the last parse result. More... | |
bool | HasParseError () const |
Whether a parse error has occured in the last parsing. More... | |
ParseErrorCode | GetParseError () const |
Get the ParseErrorCode of last parsing. More... | |
size_t | GetErrorOffset () const |
Get the position of last parsing error in input, 0 otherwise. More... | |
operator ParseResult () const | |
Implicit conversion to get the last parse result. More... | |
Friends | |
template<typename , typename > | |
class | GenericValue |
template<typename , typename > | |
class | GenericValue |
void | swap (GenericDocument &a, GenericDocument &b) RAPIDJSON_NOEXCEPT |
free-standing swap function helper More... | |
void | swap (GenericDocument &a, GenericDocument &b) RAPIDJSON_NOEXCEPT |
free-standing swap function helper More... | |
A document for parsing JSON text as DOM.
Encoding | Encoding for both parsing and string storage. |
Allocator | Allocator for allocating memory for the DOM |
StackAllocator | Allocator for allocating memory for stack during parsing. |
delete
a GenericDocument object via a pointer to a GenericValue. Definition at line 62 of file cmr_module/rapidjson/document.h.
typedef Allocator GenericDocument< Encoding, Allocator, StackAllocator >::AllocatorType |
Allocator type from template parameter.
Definition at line 2028 of file cmr_module/rapidjson/document.h.
typedef Allocator GenericDocument< Encoding, Allocator, StackAllocator >::AllocatorType |
Allocator type from template parameter.
Definition at line 2028 of file dmrpp_module/xml2json/include/rapidjson/document.h.
typedef Encoding::Ch GenericDocument< Encoding, Allocator, StackAllocator >::Ch |
Character type derived from Encoding.
Definition at line 2026 of file dmrpp_module/xml2json/include/rapidjson/document.h.
typedef Encoding::Ch GenericDocument< Encoding, Allocator, StackAllocator >::Ch |
Character type derived from Encoding.
Definition at line 2026 of file cmr_module/rapidjson/document.h.
typedef GenericValue<Encoding, Allocator> GenericDocument< Encoding, Allocator, StackAllocator >::ValueType |
Value type of the document.
Definition at line 2027 of file cmr_module/rapidjson/document.h.
typedef GenericValue<Encoding, Allocator> GenericDocument< Encoding, Allocator, StackAllocator >::ValueType |
Value type of the document.
Definition at line 2027 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inlineexplicit |
Constructor.
Creates an empty document of specified type.
type | Mandatory type of object to create. |
allocator | Optional allocator for allocating memory. |
stackCapacity | Optional initial capacity of stack in bytes. |
stackAllocator | Optional allocator for allocating memory for stack. |
Definition at line 2037 of file cmr_module/rapidjson/document.h.
|
inline |
Constructor.
Creates an empty document which type is Null.
allocator | Optional allocator for allocating memory. |
stackCapacity | Optional initial capacity of stack in bytes. |
stackAllocator | Optional allocator for allocating memory for stack. |
Definition at line 2050 of file cmr_module/rapidjson/document.h.
|
inlineexplicit |
Constructor.
Creates an empty document of specified type.
type | Mandatory type of object to create. |
allocator | Optional allocator for allocating memory. |
stackCapacity | Optional initial capacity of stack in bytes. |
stackAllocator | Optional allocator for allocating memory for stack. |
Definition at line 2037 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Constructor.
Creates an empty document which type is Null.
allocator | Optional allocator for allocating memory. |
stackCapacity | Optional initial capacity of stack in bytes. |
stackAllocator | Optional allocator for allocating memory for stack. |
Definition at line 2050 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Get the allocator of this document.
Definition at line 2308 of file cmr_module/rapidjson/document.h.
|
inline |
Get the allocator of this document.
Definition at line 2308 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Get the position of last parsing error in input, 0 otherwise.
Definition at line 2290 of file cmr_module/rapidjson/document.h.
|
inline |
Get the position of last parsing error in input, 0 otherwise.
Definition at line 2290 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Get the ParseErrorCode of last parsing.
Definition at line 2287 of file cmr_module/rapidjson/document.h.
|
inline |
Get the ParseErrorCode of last parsing.
Definition at line 2287 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Get the capacity of stack in bytes.
Definition at line 2314 of file cmr_module/rapidjson/document.h.
|
inline |
Get the capacity of stack in bytes.
Definition at line 2314 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Whether a parse error has occured in the last parsing.
Definition at line 2284 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Whether a parse error has occured in the last parsing.
Definition at line 2284 of file cmr_module/rapidjson/document.h.
|
inline |
Implicit conversion to get the last parse result.
Definition at line 2304 of file cmr_module/rapidjson/document.h.
|
inline |
Implicit conversion to get the last parse result.
Definition at line 2304 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Parse JSON text from a read-only string.
parseFlags | Combination of ParseFlag (must not contain kParseInsituFlag). |
str | Read-only zero-terminated string to be parsed. |
Definition at line 2232 of file cmr_module/rapidjson/document.h.
|
inline |
Parse JSON text from a read-only string.
parseFlags | Combination of ParseFlag (must not contain kParseInsituFlag). |
str | Read-only zero-terminated string to be parsed. |
Definition at line 2232 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Parse JSON text from a read-only string (with kParseDefaultFlags)
str | Read-only zero-terminated string to be parsed. |
Definition at line 2239 of file cmr_module/rapidjson/document.h.
|
inline |
Parse JSON text from a read-only string (with kParseDefaultFlags)
str | Read-only zero-terminated string to be parsed. |
Definition at line 2239 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Parse JSON text from a read-only string (with Encoding conversion)
parseFlags | Combination of ParseFlag (must not contain kParseInsituFlag). |
SourceEncoding | Transcoding from input Encoding |
str | Read-only zero-terminated string to be parsed. |
Definition at line 2221 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Parse JSON text from a read-only string (with Encoding conversion)
parseFlags | Combination of ParseFlag (must not contain kParseInsituFlag). |
SourceEncoding | Transcoding from input Encoding |
str | Read-only zero-terminated string to be parsed. |
Definition at line 2221 of file cmr_module/rapidjson/document.h.
|
inline |
Parse JSON text from a mutable string.
parseFlags | Combination of ParseFlag. |
str | Mutable zero-terminated string to be parsed. |
Definition at line 2198 of file cmr_module/rapidjson/document.h.
|
inline |
Parse JSON text from a mutable string.
parseFlags | Combination of ParseFlag. |
str | Mutable zero-terminated string to be parsed. |
Definition at line 2198 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Parse JSON text from a mutable string (with kParseDefaultFlags)
str | Mutable zero-terminated string to be parsed. |
Definition at line 2207 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Parse JSON text from a mutable string (with kParseDefaultFlags)
str | Mutable zero-terminated string to be parsed. |
Definition at line 2207 of file cmr_module/rapidjson/document.h.
|
inline |
Parse JSON text from an input stream (with Encoding conversion)
parseFlags | Combination of ParseFlag. |
SourceEncoding | Encoding of input stream |
InputStream | Type of input stream, implementing Stream concept |
is | Input stream to be parsed. |
Definition at line 2155 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Parse JSON text from an input stream (with Encoding conversion)
parseFlags | Combination of ParseFlag. |
SourceEncoding | Encoding of input stream |
InputStream | Type of input stream, implementing Stream concept |
is | Input stream to be parsed. |
Definition at line 2155 of file cmr_module/rapidjson/document.h.
|
inline |
Parse JSON text from an input stream.
parseFlags | Combination of ParseFlag. |
InputStream | Type of input stream, implementing Stream concept |
is | Input stream to be parsed. |
Definition at line 2174 of file cmr_module/rapidjson/document.h.
|
inline |
Parse JSON text from an input stream.
parseFlags | Combination of ParseFlag. |
InputStream | Type of input stream, implementing Stream concept |
is | Input stream to be parsed. |
Definition at line 2174 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Parse JSON text from an input stream (with kParseDefaultFlags)
InputStream | Type of input stream, implementing Stream concept |
is | Input stream to be parsed. |
Definition at line 2184 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Parse JSON text from an input stream (with kParseDefaultFlags)
InputStream | Type of input stream, implementing Stream concept |
is | Input stream to be parsed. |
Definition at line 2184 of file cmr_module/rapidjson/document.h.
|
inline |
Populate this document by a generator which produces SAX events.
Generator | A functor with bool f(Handler) prototype. |
g | Generator functor which sends SAX events to the parameter. |
Definition at line 2135 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Populate this document by a generator which produces SAX events.
Generator | A functor with bool f(Handler) prototype. |
g | Generator functor which sends SAX events to the parameter. |
Definition at line 2135 of file cmr_module/rapidjson/document.h.
|
inline |
Exchange the contents of this document with those of another.
rhs | Another document. |
Definition at line 2106 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
inline |
Exchange the contents of this document with those of another.
rhs | Another document. |
Definition at line 2106 of file cmr_module/rapidjson/document.h.
|
friend |
free-standing swap function helper
Helper function to enable support for common swap implementation pattern based on std::swap:
Definition at line 2127 of file dmrpp_module/xml2json/include/rapidjson/document.h.
|
friend |
free-standing swap function helper
Helper function to enable support for common swap implementation pattern based on std::swap:
Definition at line 2127 of file cmr_module/rapidjson/document.h.