Constructors

Synopses

Declared in <baljsn_simpleformatter.h>

Create a SimpleFormatter that writes JSON to the specified stream.

explicit
SimpleFormatter(
    std::ostream& stream,
    bslma::Allocator* basicAllocator = 0);

Create a SimpleFormatter object having the same value as original.

SimpleFormatter(
    SimpleFormatter const& original,
    bslma::Allocator* basicAllocator);

Create a SimpleFormatter that writes JSON to stream using encoderOptions.

explicit
SimpleFormatter(
    std::ostream& stream,
    EncoderOptions const& encoderOptions,
    bslma::Allocator* basicAllocator = 0);

Parameters

Name

Description

stream

output stream for formatted JSON

basicAllocator

memory allocator; null uses the default

original

object to copy

encoderOptions

options configuring JSON output

Created with MrDocs