|
uvw 2.12.1
|
Common class for almost all the resources available in uvw.
More...
#include <resource.hpp>


Public Member Functions | |
| template<typename R = void> | |
| std::shared_ptr< R > | data () const |
Gets user-defined data. uvw won't use this field in any case. | |
| void | data (std::shared_ptr< void > uData) |
Sets arbitrary data. uvw won't use this field in any case. | |
Public Member Functions inherited from uvw::UnderlyingType< T, U > | |
| Loop & | loop () const noexcept |
| Gets the loop from which the resource was originated. | |
| const U * | raw () const noexcept |
| Gets the underlying raw data structure. | |
| U * | raw () noexcept |
| Gets the underlying raw data structure. | |
Public Member Functions inherited from uvw::Emitter< T > | |
| template<typename E> | |
| Connection< E > | on (Listener< E > f) |
| Registers a long-lived listener with the event emitter. | |
| template<typename E> | |
| Connection< E > | once (Listener< E > f) |
| Registers a short-lived listener with the event emitter. | |
| template<typename E> | |
| void | erase (Connection< E > conn) noexcept |
| Disconnects a listener from the event emitter. | |
| template<typename E> | |
| void | clear () noexcept |
| Disconnects all the listeners for the given event type. | |
| void | clear () noexcept |
| Disconnects all the listeners. | |
| template<typename E> | |
| bool | empty () const noexcept |
| Checks if there are listeners registered for the specific event. | |
| bool | empty () const noexcept |
| Checks if there are listeners registered with the event emitter. | |
Additional Inherited Members | |
Static Public Member Functions inherited from uvw::UnderlyingType< T, U > | |
| template<typename... Args> | |
| static std::shared_ptr< T > | create (Args &&...args) |
| Creates a new resource of the given type. | |
Common class for almost all the resources available in uvw.
This is the base class for handles and requests.
Definition at line 17 of file resource.hpp.
|
inline |
Gets user-defined data. uvw won't use this field in any case.
Definition at line 48 of file resource.hpp.
|
inline |
Sets arbitrary data. uvw won't use this field in any case.
| uData | User-defined arbitrary data. |
Definition at line 56 of file resource.hpp.