Encode datum as JSON into result as a std::pmr::string.
Declared in <baljsn_datumutil.h>
static
int
encode(
std::pmr::string* result,
bdld::Datum const& datum);
Same as the preceding overload, loading into a std::pmr::string.
0 on success, a negative value on failure, or a positive value if strictTypes is enabled and an unsupported type is encoded
| Name | Description |
|---|---|
| result | receives the encoded JSON string |
| datum | Datum to encode |