class EE::Scene::EventConnectionList¶
Overview¶
Owns a small group of event connections and disconnects them together. More…
#include <eventconnection.hpp> class EventConnectionList { public: // construction EventConnectionList(); EventConnectionList(EventConnectionList&&); EventConnectionList(const EventConnectionList&); // methods EventConnectionList& operator=(EventConnectionList&&); EventConnectionList& operator=(const EventConnectionList&); EventConnectionList& add(EventConnection connection); EventConnectionList& operator+=(EventConnection connection); void clear(); bool empty() const; size_t size() const; };
Detailed Documentation¶
Owns a small group of event connections and disconnects them together.
The first four connections are stored inline. Destroying or clearing the list destroys every contained EventConnection and therefore disconnects all of their listeners. As with an individual EventConnection, the list must be manipulated on the emitters’ owning thread.
Methods¶
EventConnectionList& add(EventConnection connection)
Adds a connection by transferring its ownership into this list.
EventConnectionList& operator+=(EventConnection connection)
Equivalent to add().
void clear()
Disconnects and removes all owned connections.
bool empty() const
Returns:
True if the list owns no connections.
size_t size() const
Returns:
The number of connections owned by the list.