Enum ParseFlag

Description

Combination of parseFlags.

See
Reader::Parse, Document::Parse, Document::ParseInsitu, Document::ParseStream

Values

kParseNoFlags = 0

No flags are set.

Mentioned in:

Dom / Parsing {#Parsing}

kParseInsituFlag = 1

In-situ(destructive) parsing.

Mentioned in:

Dom / Parsing {#Parsing}

kParseValidateEncodingFlag = 2

Validate encoding of JSON strings.

Mentioned in:

Encoding / Validation & Transcoding {#ValidationTranscoding}

Dom / Parsing {#Parsing}

Dom / Transcoding and Validation {#TranscodingAndValidation}

Faq / Unicode

Examples / pretty.cpp

Examples / prettyauto.cpp

kParseIterativeFlag = 4

Iterative(constant complexity in terms of function call stack size) parsing.

Mentioned in:

Dom / Parsing {#Parsing}

kParseStopWhenDoneFlag = 8

After parsing a complete JSON root from stream, stop further processing the rest of stream. When this flag is used, parser will not generate kParseErrorDocumentRootNotSingular error.

Mentioned in:

Changelog / Added

Features / Parsing

Dom / Parsing {#Parsing}

kParseFullPrecisionFlag = 16

Parse number in full precision (but slower).

Mentioned in:

Changelog / Added

Dom / Parsing {#Parsing}

Internals / Parsing to Double {#ParsingDouble}

kParseCommentsFlag = 32

Allow one-line (//) and multi-line (/‍‍**/) comments.

Mentioned in:

Features / Standard compliance

Dom / Parsing {#Parsing}

kParseNumbersAsStringsFlag = 64

Parse all numbers (ints/doubles) as strings.

Mentioned in:

Dom / Parsing {#Parsing}

kParseTrailingCommasFlag = 128

Allow trailing commas at the end of objects and arrays.

Mentioned in:

Features / Standard compliance

Dom / Parsing {#Parsing}

kParseNanAndInfFlag = 256

Allow parsing NaN, Inf, Infinity, -Inf and -Infinity as doubles.

Mentioned in:

Features / Standard compliance

Dom / Parsing {#Parsing}

kParseEscapedApostropheFlag = 512

Allow escaped apostrophe in strings.

Mentioned in:

Dom / Parsing {#Parsing}

kParseDefaultFlags = RAPIDJSON_PARSE_DEFAULT_FLAGS

Default parse flags. Can be customized by defining RAPIDJSON_PARSE_DEFAULT_FLAGS.

Mentioned in:

Dom / Parsing {#Parsing}

Sax / Token-by-Token Parsing {#TokenByTokenParsing}

Schema / DOM parsing {#DOM}

Examples / parsebyparts.cpp

Source

Lines 146-159 in include/rapidjson/reader.h.

enum ParseFlag {
    kParseNoFlags = 0,              //!< No flags are set.
    kParseInsituFlag = 1,           //!< In-situ(destructive) parsing.
    kParseValidateEncodingFlag = 2, //!< Validate encoding of JSON strings.
    kParseIterativeFlag = 4,        //!< Iterative(constant complexity in terms of function call stack size) parsing.
    kParseStopWhenDoneFlag = 8,     //!< After parsing a complete JSON root from stream, stop further processing the rest of stream. When this flag is used, parser will not generate kParseErrorDocumentRootNotSingular error.
    kParseFullPrecisionFlag = 16,   //!< Parse number in full precision (but slower).
    kParseCommentsFlag = 32,        //!< Allow one-line (//) and multi-line (/**/) comments.
    kParseNumbersAsStringsFlag = 64,    //!< Parse all numbers (ints/doubles) as strings.
    kParseTrailingCommasFlag = 128, //!< Allow trailing commas at the end of objects and arrays.
    kParseNanAndInfFlag = 256,      //!< Allow parsing NaN, Inf, Infinity, -Inf and -Infinity as doubles.
    kParseEscapedApostropheFlag = 512,  //!< Allow escaped apostrophe in strings.
    kParseDefaultFlags = RAPIDJSON_PARSE_DEFAULT_FLAGS  //!< Default parse flags. Can be customized by defining RAPIDJSON_PARSE_DEFAULT_FLAGS
};





Add Discussion as Guest

Log in