#include <utilmm/system/socket.hh>

Public Types | |
| enum | Domain { Unix, Inet } |
| enum | Type { Stream, Datagram } |
| enum | Wait { WaitRead = 1, WaitWrite = 2, WaitException = 4 } |
Public Member Functions | |
| base_socket (int fd) | |
| base_socket (Domain domain, Type type) | |
| ~base_socket () | |
| int | fd () const |
| bool | try_wait (int what) const |
| void | wait (int what) const |
| void | flush () const |
Protected Member Functions | |
| std::vector< uint8_t > | to_sockaddr (std::string const &to) const |
Classes | |
| struct | bad_address |
| utilmm::base_socket::base_socket | ( | int | fd | ) |
| utilmm::base_socket::~base_socket | ( | ) |
Closes the socket
| std::vector<uint8_t> utilmm::base_socket::to_sockaddr | ( | std::string const & | to | ) | const [protected] |
| int utilmm::base_socket::fd | ( | ) | const |
Get the socket file descriptor
| bool utilmm::base_socket::try_wait | ( | int | what | ) | const |
Non-blocking version of wait
| what | an OR-ed field of values in the Wait enum |
| void utilmm::base_socket::wait | ( | int | what | ) | const |
Blocks until one of the specified events is detected on this socket
| what | an OR-ed field of values in the Wait enum |
| void utilmm::base_socket::flush | ( | ) | const |
Flush all buffers related to this socket
1.5.3