[#BloombergLP-bdljsn-JsonObject-swap]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdljsn.adoc[bdljsn]::xref:BloombergLP/bdljsn/JsonObject.adoc[JsonObject]::swap
:relfileprefix: ../../../
:mrdocs:

Exchange the value of this object with that of the specified `other` object&period; If an exception is thrown, both objects are left in valid but unspecified states&period; This operation guarantees O&lsqb;1&rsqb;complexity&period; The behavior is undefined unless this object was created with the same allocator as `other`&period;

== Synopsis

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

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
void
swap(xref:BloombergLP/bdljsn/JsonObject.adoc[JsonObject]& other);
----


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