|
CeresEngine 0.2.0
A game development framework
|
Scoped connection class. More...
#include <CeresEngine/Foundation/Event.hpp>
Public Member Functions | |
| EventConnection () noexcept=default | |
| Scoped are default constructible. | |
| EventConnection (EventConnection const &)=delete | |
| Scoped connections are not copy constructible. | |
| EventConnection & | operator= (EventConnection const &)=delete |
| Scoped connections are not copy assingable. | |
| EventConnection (EventConnection &&other) noexcept | |
| Move constructor. | |
| EventConnection & | operator= (EventConnection &&other) noexcept |
| Move assign operator. | |
| EventConnection (WeakEventConnection &&c) noexcept | |
| Construct a scoped connection from a connection object. | |
| ~EventConnection () | |
| destructor | |
| EventConnection & | operator= (WeakEventConnection &&c) |
| Assignment operator moving a new connection into the instance. | |
| void | reset (WeakEventConnection &&c={}) |
| Reset the underlying connection to another connection. | |
| WeakEventConnection | release () noexcept |
| Release the underlying connection, without disconnecting it. | |
| bool | connected () const noexcept |
| void | disconnect () |
| Disconnect the slot from the connection. | |
Private Attributes | |
| WeakEventConnection | connection |
| Underlying connection object. | |
Scoped connection class.
This type of connection is automatically disconnected when the connection object is destructed.
|
defaultnoexcept |
Scoped are default constructible.
|
delete |
Scoped connections are not copy constructible.
|
inlinenoexcept |
Move constructor.
|
inlinenoexcept |
Construct a scoped connection from a connection object.
| c | The connection object to manage |
|
inline |
destructor
|
inlinenoexcept |
true if the connection is connected to a event object, and false otherwise.
|
inline |
Disconnect the slot from the connection.
If the connection represents a slot that is connected to a event object, calling this method will disconnect the slot from that object. The result of this operation is that the slot will stop receiving calls when the event is invoked.
|
inlinenoexcept |
Move assign operator.
| other | The instance to move from. |
|
delete |
Scoped connections are not copy assingable.
|
inline |
Assignment operator moving a new connection into the instance.
| c | New connection to manage |
|
inlinenoexcept |
Release the underlying connection, without disconnecting it.
|
inline |
Reset the underlying connection to another connection.
| c | New connection to manage |
|
private |
Underlying connection object.