|
uvw
2.10.0
|
The GetAddrInfoReq request. More...
#include <dns.h>


Public Member Functions | |
| void | nodeAddrInfo (const std::string &node, addrinfo *hints=nullptr) |
| Async getaddrinfo. More... | |
| std::pair< bool, std::unique_ptr< addrinfo, Deleter > > | nodeAddrInfoSync (const std::string &node, addrinfo *hints=nullptr) |
| Sync getaddrinfo. More... | |
| void | serviceAddrInfo (const std::string &service, addrinfo *hints=nullptr) |
| Async getaddrinfo. More... | |
| std::pair< bool, std::unique_ptr< addrinfo, Deleter > > | serviceAddrInfoSync (const std::string &service, addrinfo *hints=nullptr) |
| Sync getaddrinfo. More... | |
| void | addrInfo (const std::string &node, const std::string &service, addrinfo *hints=nullptr) |
| Async getaddrinfo. More... | |
| std::pair< bool, std::unique_ptr< addrinfo, Deleter > > | addrInfoSync (const std::string &node, const std::string &service, addrinfo *hints=nullptr) |
| Sync getaddrinfo. More... | |
Public Member Functions inherited from uvw::Request< GetAddrInfoReq, uv_getaddrinfo_t > | |
| bool | cancel () |
| Cancels a pending request. More... | |
| std::size_t | size () const noexcept |
| Returns the size of the underlying request type. More... | |
Public Member Functions inherited from uvw::Resource< T, U > | |
| template<typename R = void> | |
| std::shared_ptr< R > | data () const |
Gets user-defined data. uvw won't use this field in any case. More... | |
| void | data (std::shared_ptr< void > uData) |
Sets arbitrary data. uvw won't use this field in any case. More... | |
Public Member Functions inherited from uvw::UnderlyingType< T, U > | |
| Loop & | loop () const noexcept |
| Gets the loop from which the resource was originated. More... | |
| const U * | raw () const noexcept |
| Gets the underlying raw data structure. More... | |
| U * | raw () noexcept |
| Gets the underlying raw data structure. More... | |
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. More... | |
| template<typename E > | |
| Connection< E > | once (Listener< E > f) |
| Registers a short-lived listener with the event emitter. More... | |
| template<typename E > | |
| void | erase (Connection< E > conn) noexcept |
| Disconnects a listener from the event emitter. More... | |
| 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. More... | |
| bool | empty () const noexcept |
| Checks if there are listeners registered with the event emitter. More... | |
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. More... | |
The GetAddrInfoReq request.
Wrapper for getaddrinfo.
It offers either asynchronous and synchronous access methods.
To create a GetAddrInfoReq through a Loop, no arguments are required.
| void uvw::GetAddrInfoReq::addrInfo | ( | const std::string & | node, |
| const std::string & | service, | ||
| addrinfo * | hints = nullptr |
||
| ) |
Async getaddrinfo.
| node | Either a numerical network address or a network hostname. |
| service | Either a service name or a port number as a string. |
| hints | Optional addrinfo data structure with additional address type constraints. |
| std::pair<bool, std::unique_ptr<addrinfo, Deleter> > uvw::GetAddrInfoReq::addrInfoSync | ( | const std::string & | node, |
| const std::string & | service, | ||
| addrinfo * | hints = nullptr |
||
| ) |
Sync getaddrinfo.
| node | Either a numerical network address or a network hostname. |
| service | Either a service name or a port number as a string. |
| hints | Optional addrinfo data structure with additional address type constraints. |
std::pair composed as it follows:std::unique_ptr<addrinfo, Deleter> containing the data requested. | void uvw::GetAddrInfoReq::nodeAddrInfo | ( | const std::string & | node, |
| addrinfo * | hints = nullptr |
||
| ) |
Async getaddrinfo.
| node | Either a numerical network address or a network hostname. |
| hints | Optional addrinfo data structure with additional address type constraints. |
| std::pair<bool, std::unique_ptr<addrinfo, Deleter> > uvw::GetAddrInfoReq::nodeAddrInfoSync | ( | const std::string & | node, |
| addrinfo * | hints = nullptr |
||
| ) |
Sync getaddrinfo.
| node | Either a numerical network address or a network hostname. |
| hints | Optional addrinfo data structure with additional address type constraints. |
std::pair composed as it follows:std::unique_ptr<addrinfo, Deleter> containing the data requested. | void uvw::GetAddrInfoReq::serviceAddrInfo | ( | const std::string & | service, |
| addrinfo * | hints = nullptr |
||
| ) |
Async getaddrinfo.
| service | Either a service name or a port number as a string. |
| hints | Optional addrinfo data structure with additional address type constraints. |
| std::pair<bool, std::unique_ptr<addrinfo, Deleter> > uvw::GetAddrInfoReq::serviceAddrInfoSync | ( | const std::string & | service, |
| addrinfo * | hints = nullptr |
||
| ) |
Sync getaddrinfo.
| service | Either a service name or a port number as a string. |
| hints | Optional addrinfo data structure with additional address type constraints. |
std::pair composed as it follows:std::unique_ptr<addrinfo, Deleter> containing the data requested.