[#BloombergLP-bdlmt-SignalerConnectionGuard-2constructor-02]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdlmt.adoc[bdlmt]::xref:BloombergLP/bdlmt/SignalerConnectionGuard.adoc[SignalerConnectionGuard]::SignalerConnectionGuard
:relfileprefix: ../../../
:mrdocs:

Create a guard by moving from `connection`&period;

== Synopsis

Declared in `&lt;bdlmt&lowbar;signaler&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
explicit
SignalerConnectionGuard(
    xref:BloombergLP/bslmf/MovableRef.adoc[bslmf::MovableRef&lt;SignalerConnection&gt;] connection,
    bool waitOnDisconnect = false) noexcept;
----

== Description

Create a `SignalerConnectionGuard` that refers to the same slot, if any, as the specified `connection`, which is left in an unspecified state&period; Optionally specify `waitOnDisconnect` indicating whether `disconnect` or `disconnectAndWait` will be called on the slot, if any, managed by this object upon destruction or assignment&period; Throws nothing&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *connection*
| connection to move from
| *waitOnDisconnect*
| if `true`, use `disconnectAndWait` on release
|===


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