REST.Json.TJsonOption

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

TJsonOption = (joIgnoreEmptyStrings, joIgnoreEmptyArrays, joDateIsUTC, joDateFormatUnix, joDateFormatISO8601, joDateFormatMongo, joDateFormatParse);

C++

enum DECLSPEC_DENUM TJsonOption : unsigned char { joIgnoreEmptyStrings, joIgnoreEmptyArrays, joDateIsUTC, joDateFormatUnix, joDateFormatISO8601, joDateFormatMongo, joDateFormatParse };

Properties

Type Visibility Source Unit Parent
enum public
REST.Json.pas
REST.Json.hpp
REST.Json REST.Json

Description

Specifies the format options.

Option Description

joDateFormatISO8601

Date format as specified in the ISO 8601 standard. For example: "2014-12-01T13:14:18Z" (Mon, 01 Dec 2014 13:14:18 UTC).

joDateFormatMongo

Date format as specified in MongoDB Extended JSON. For example: { "$date": "2014-12-01T13:14:18.000+00:00" } (Mon, 01 Dec 2014 13:14:18 UTC).

joDateFormatUnix

Date format as specified in the Unix time. For example: "1417439658" (Mon, 01 Dec 2014 13:14:18 UTC).

joDateIsUTC

Time format as specified in the UTC time standard.

joIgnoreEmptyArrays

Format that ignores key-value pairs when the value of a pair is an empty JSON array.

For example, for the following pairs: { "key1": [], "key2": "value2" }, the joIgnoreEmptyArrays format option considers the resulting JSON code as: { "key2": "value2" } instead.

joIgnoreEmptyStrings

Format that ignores key-value pairs when the value of a pair is an empty string.

For example, for the following pairs: { "key1": "value1", "key2": "" }, the joIgnoreEmptyStrings format option considers the resulting JSON code as: { "key1": "value1" } instead.

See Also