The ScopedConnection class disconnects a connection when it goes out of scope.
More...
#include <qx/utility/qx-helpers.h>
This is useful when you have a connection that you want disconnected when a certain context is left, but do not have a QObject based context object to use.
- See also
- scopedConnect().
◆ ScopedConnection() [1/2]
Creates a scoped connection guard from connection.
◆ ScopedConnection() [2/2]
◆ ~ScopedConnection()
Qx::ScopedConnection::~ScopedConnection |
( |
| ) |
|
|
inline |
Destroys the scoped connection guard. The underlying connection will be disconnected if it's valid.
◆ operator bool()
Qx::ScopedConnection::operator bool |
( |
| ) |
const |
|
inline |
Returns true
if the underlying connection is valid (was successful when connect was called); otherwise, returns false
.
◆ operator=()
Move assigns this ScopedCOnnection using other.
The documentation for this class was generated from the following files: