record TgoJsonWriterSettings

DescriptionHierarchyFieldsMethodsProperties

Unit

Declaration

type TgoJsonWriterSettings = record

Description

Settings for a IgoJsonWriter

Overview

Methods

class function Create: TgoJsonWriterSettings; overload; static;
class function Create(const APrettyPrint: Boolean; const AOutputMode: TgoJsonOutputMode = TgoJsonOutputMode.Strict): TgoJsonWriterSettings; overload; static;
class function Create(const AIndent, ALineBreak: String; const AOutputMode: TgoJsonOutputMode = TgoJsonOutputMode.Strict): TgoJsonWriterSettings; overload; static;
class function Create(const AOutputMode: TgoJsonOutputMode): TgoJsonWriterSettings; overload; static;

Properties

property Default: TgoJsonWriterSettings read FDefault;
property Shell: TgoJsonWriterSettings read FShell;
property Pretty: TgoJsonWriterSettings read FPretty;
property PrettyPrint: Boolean read FPrettyPrint write FPrettyPrint;
property Indent: String read FIndent write FIndent;
property LineBreak: String read FLineBreak write FLineBreak;
property OutputMode: TgoJsonOutputMode read FOutputMode write FOutputMode;

Description

Methods

class function Create: TgoJsonWriterSettings; overload; static;

Creates a settings record using the default settings:

Returns

The settings

class function Create(const APrettyPrint: Boolean; const AOutputMode: TgoJsonOutputMode = TgoJsonOutputMode.Strict): TgoJsonWriterSettings; overload; static;

Creates a settings record:

Parameters
APrettyPrint
whether to use indentation (see Indent) and line breaks (see LineBreak).
AOutputMode
(optional) output mode. Defaults to Strict.
Returns

The settings

class function Create(const AIndent, ALineBreak: String; const AOutputMode: TgoJsonOutputMode = TgoJsonOutputMode.Strict): TgoJsonWriterSettings; overload; static;

Creates a settings record:

Note: this constructor sets PrettyPrint to True.

Parameters
AIndent
the string to use for indentation. Should only contain whitespace characters to create valid output.
ALineBreak
the string to use for line breaks. Should only contain whitespace characters to create valid output.
AOutputMode
(optional) output mode. Defaults to Strict.
Returns

The settings.

class function Create(const AOutputMode: TgoJsonOutputMode): TgoJsonWriterSettings; overload; static;

Creates a settings record:

Note: this constructor sets PrettyPrint to False.

Parameters
AOutputMode
output mode to use.
Returns

The settings

Properties

property Default: TgoJsonWriterSettings read FDefault;

The default settings:

property Shell: TgoJsonWriterSettings read FShell;

"Shell" settings for outputing JSON with MongoDB shell extensions.

property Pretty: TgoJsonWriterSettings read FPretty;

Settings for outputing JSON compliant JSON in a pretty format.

property PrettyPrint: Boolean read FPrettyPrint write FPrettyPrint;

Whether to use indentation (see Indent) and line breaks (see LineBreak). Default False.

property Indent: String read FIndent write FIndent;

String to use for indentation. Should only contain whitespace characters to create valid output. Not used unless PrettyPrint is True. Defaults to 2 spaces

property LineBreak: String read FLineBreak write FLineBreak;

String to use for line breaks. Should only contain whitespace characters to create valid output. Not used unless PrettyPrint is True. Defaults to CR+LF

property OutputMode: TgoJsonOutputMode read FOutputMode write FOutputMode;

Output mode to use. Defaults to Strict


Generated by P2PasDoc 0.13.0 on 2017-04-25 12:54:26