BDE 4.14.0 Production release
|
Enumerate the formatting styles for a writing a JSON document.
This component provides bdljsn::WriteStyle
, a namespace for the enum
type bdljsn::WriteStyle::Enum
, which enumerates the set of format styles that can be used when writing a JSON document.
This section illustrates intended use of this component.
The following snippets of code provide a simple illustration of using bdljsn::WriteStyle
.
First, we create a variable value
of type bdljsn::WriteStyle::Enum
and initialize it with the enumerator value bdljsn::WriteStyle::e_PRETTY
:
Now, we store the address of its ASCII representation in a pointer variable, asciiValue
, of type const char *
:
Finally, we print value
to bsl::cout
.
This statement produces the following output on stdout
: