Create a Json object having the type bsl::string and the same value as the specified string by moving (in constant time) the contents of string to the new Json object. Optionally specify the basicAllocator used to supply memory. If basicAllocator is not specified, the allocator associated with string is propagated for use in the newly‐created Json object. string is left in a valid but unspecified state. This function does not participate in overload resolution unless the specified t_STRING_TYPE is bsl::string. The behavior is undefined unless string is valid UTF‐8 (see bdlde::Utf8Util::isValid).
Synopsis
Declared in <bdljsn_json.h>
template<class t_STRING_TYPE>
Json(
BloombergLP::bslmf::MovableRef_Deduced<t_STRING_TYPE> string,
bslma::Allocator* basicAllocator = 0,
void* = 0)
requires bsl::is_same<t_STRING_TYPE,
bsl::string>::value;
Created with MrDocs