Struct ConnectHandle
pub struct ConnectHandle { /* private fields */ }Expand description
Handle representing a typed signal connection to a receiver.
Returned by connections made by the connect_* methods of
TypedSignal and ConnectBuilder.
Connections managed by a handle can be disconnected using disconnect().
Implementations§
§impl ConnectHandle
impl ConnectHandle
pub fn disconnect(self)
pub fn disconnect(self)
Disconnects the signal from the connected callable.
§Panics (safeguards-balanced)
If the connection does not exist. Use is_connected() to make sure the connection exists.
pub fn is_connected(&self) -> bool
pub fn is_connected(&self) -> bool
Whether the handle represents a valid connection.
Returns false if:
- … the signals and callables managed by this handle have been disconnected in any other way than by using
disconnect()– e.g. throughSignal::disconnect()orObject::disconnect(). - … the broadcasting object managed by this handle is not valid – e.g. if the object has been freed.