|
| | Socket (boost::asio::io_context &io, std::string_view label) noexcept |
| | Construct a netlink Socket with an io_context and label.
|
| | ~Socket () noexcept |
| | Destroy the Socket object and ensure underlying socket is closed.
|
| | Socket (const Socket &)=delete |
| Socket & | operator= (const Socket &)=delete |
| | Socket (Socket &&) noexcept=default |
| Socket & | operator= (Socket &&) noexcept=default |
| auto | is_open () const noexcept -> bool |
| | Check whether the socket is currently open.
|
| auto | close () -> std::expected< void, std::error_code > |
| | Close the underlying socket.
|
| auto | cancel () -> std::expected< void, std::error_code > |
| | Cancel any asynchronous operations on the socket.
|
| auto | open (int proto, uint32_t groups) -> std::expected< void, std::error_code > |
| | Open and configure the netlink socket.
|
| template<typename Option> |
| void | set_option (const Option &option, boost::system::error_code &ec) |
| template<typename Endpoint> |
| void | bind (const Endpoint &endpoint, boost::system::error_code &ec) |
| template<typename Endpoint> |
| void | connect (const Endpoint &endpoint, boost::system::error_code &ec) |
| template<typename MutableBufferSequence, typename CompletionToken> |
| auto | async_receive (const MutableBufferSequence &buffers, CompletionToken &&token) -> decltype(std::declval< socket_t >().async_receive(buffers, std::forward< CompletionToken >(token))) |
| template<typename MutableBufferSequence> |
| auto | receive (const MutableBufferSequence &buffers, boost::system::error_code &ec) -> size_t |
| template<typename ConstBufferSequence, typename CompletionToken> |
| auto | async_send (const ConstBufferSequence &buffers, CompletionToken &&token) -> decltype(std::declval< socket_t >() .async_send(buffers, std::forward< CompletionToken >(token))) |
| template<typename ConstBufferSequence> |
| auto | send (const ConstBufferSequence &buffers, boost::system::error_code &ec) -> size_t |
| auto | native_handle () -> native_t |
| | Get the native socket handle.
|
RAII wrapper for a Boost.Asio netlink socket.
Encapsulates socket creation, option configuration, bind, and teardown for Netlink protocol sockets used by rtaco.