[#BloombergLP-bdljsn-JsonObject-2constructor-030]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdljsn.adoc[bdljsn]::xref:BloombergLP/bdljsn/JsonObject.adoc[JsonObject]::JsonObject
:relfileprefix: ../../../
:mrdocs:

Create a `JsonObject` by moving from `original` using `basicAllocator`&period;

== Synopsis

Declared in `&lt;bdljsn&lowbar;json&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
JsonObject(
    xref:BloombergLP/bslmf/MovableRef.adoc[bslmf::MovableRef&lt;JsonObject&gt;] original,
    xref:BloombergLP/bslma/Allocator.adoc[bslma::Allocator]* basicAllocator);
----

== Description

Create a `JsonObject` having the same value as the specified `original`&period; Use the specified `basicAllocator` to supply memory&period; If `basicAllocator &equals;&equals; original&period;allocator()` the value of `original` will be moved (in constant time) to the newly&hyphen;created `JsonObject`, and `original` will be left in a valid but unspecified state&period; Otherwise, `original` is copied, and `basicAllocator` used to supply memory&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *original*
| source object
| *basicAllocator*
| memory allocator&semi; null uses the default
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
