[#BloombergLP-bslma-ManagedPtr_Members-swap]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bslma.adoc[bslma]::xref:BloombergLP/bslma/ManagedPtr_Members.adoc[ManagedPtr&lowbar;Members]::swap
:relfileprefix: ../../../
:mrdocs:

Efficiently exchange the state of this object with that of `other`&period;

== Synopsis

Declared in `&lt;bslma&lowbar;managedptr&lowbar;members&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
void
swap(xref:BloombergLP/bslma/ManagedPtr_Members.adoc[ManagedPtr&lowbar;Members]& other);
----

== Description

Efficiently exchange the state of this object with the state of the specified `other` object&period; This method provides the no&hyphen;throw exception&hyphen;safety guarantee&period; Note that if either object is in an unset state, then the only guarantee about the unset state that may be exchanged is that the `pointer` value shall be null&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *other*
| object with which to exchange state
|===


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