Toolbox snapshot
The Reactive C++ Toolbox
Loading...
Searching...
No Matches
Public Types | Public Member Functions | List of all members
toolbox::net::StreamSockClnt Struct Reference

Active Client Stream Socket. All state is in base class, so object can be sliced. More...

#include <toolbox/net/StreamSock.hpp>

Inheritance diagram for toolbox::net::StreamSockClnt:
Inheritance graph
[legend]
Collaboration diagram for toolbox::net::StreamSockClnt:
Collaboration graph
[legend]

Public Types

using Protocol = StreamProtocol
 
using Endpoint = StreamEndpoint
 

Public Member Functions

 StreamSockClnt (Protocol protocol, std::error_code &ec) noexcept
 
 StreamSockClnt (Protocol protocol)
 
 StreamSockClnt () noexcept=default
 
void get_sock_name (Endpoint &ep, std::error_code &ec) noexcept
 
void get_sock_name (Endpoint &ep)
 
void connect (const Endpoint &ep, std::error_code &ec) noexcept
 
void connect (const Endpoint &ep)
 
 IoSock () noexcept=default
 
- Public Member Functions inherited from toolbox::net::IoSock
 IoSock () noexcept=default
 
void shutdown (int how)
 
ssize_t read (void *buf, std::size_t len, std::error_code &ec) noexcept
 
std::size_t read (void *buf, std::size_t len)
 
ssize_t read (MutableBuffer buf, std::error_code &ec) noexcept
 
std::size_t read (MutableBuffer buf)
 
ssize_t recv (void *buf, std::size_t len, int flags, std::error_code &ec) noexcept
 
std::size_t recv (void *buf, std::size_t len, int flags)
 
ssize_t recv (MutableBuffer buf, int flags, std::error_code &ec) noexcept
 
std::size_t recv (MutableBuffer buf, int flags)
 
ssize_t write (const void *buf, std::size_t len, std::error_code &ec) noexcept
 
std::size_t write (const void *buf, std::size_t len)
 
ssize_t write (ConstBuffer buf, std::error_code &ec) noexcept
 
std::size_t write (ConstBuffer buf)
 
ssize_t send (const void *buf, std::size_t len, int flags, std::error_code &ec) noexcept
 
std::size_t send (const void *buf, std::size_t len, int flags)
 
ssize_t send (ConstBuffer buf, int flags, std::error_code &ec) noexcept
 
std::size_t send (ConstBuffer buf, int flags)
 
 Sock (FileHandle &&sock, int family)
 
 Sock () noexcept=default
 
- Public Member Functions inherited from toolbox::net::Sock
 Sock (FileHandle &&sock, int family)
 
 Sock () noexcept=default
 
int family () const noexcept
 
bool is_ip_family () const noexcept
 
std::error_code get_error (std::error_code &ec) const noexcept
 
std::error_code get_error () const
 
int get_rcv_buf (std::error_code &ec) const noexcept
 
int get_rcv_buf () const
 
int get_snd_buf (std::error_code &ec) const noexcept
 
int get_snd_buf () const
 
bool is_tcp_no_delay (std::error_code &ec) const noexcept
 
bool is_tcp_no_delay () const
 
void close ()
 
void set_non_block (std::error_code &ec) noexcept
 
void set_non_block ()
 
void set_rcv_buf (int size, std::error_code &ec) noexcept
 
void set_rcv_buf (int size)
 
void set_reuse_addr (bool enabled, std::error_code &ec) noexcept
 
void set_reuse_addr (bool enabled)
 
void set_snd_buf (int size, std::error_code &ec) noexcept
 
void set_snd_buf (int size)
 

Detailed Description

Active Client Stream Socket. All state is in base class, so object can be sliced.

Definition at line 63 of file StreamSock.hpp.

Member Typedef Documentation

◆ Protocol

Definition at line 64 of file StreamSock.hpp.

◆ Endpoint

Definition at line 65 of file StreamSock.hpp.

Constructor & Destructor Documentation

◆ StreamSockClnt() [1/3]

toolbox::net::StreamSockClnt::StreamSockClnt ( Protocol  protocol,
std::error_code &  ec 
)
inlinenoexcept

Definition at line 69 of file StreamSock.hpp.

◆ StreamSockClnt() [2/3]

toolbox::net::StreamSockClnt::StreamSockClnt ( Protocol  protocol)
inlineexplicit

Definition at line 73 of file StreamSock.hpp.

◆ StreamSockClnt() [3/3]

toolbox::net::StreamSockClnt::StreamSockClnt ( )
defaultnoexcept

Member Function Documentation

◆ get_sock_name() [1/2]

void toolbox::net::StreamSockClnt::get_sock_name ( Endpoint ep,
std::error_code &  ec 
)
inlinenoexcept

Definition at line 80 of file StreamSock.hpp.

◆ get_sock_name() [2/2]

void toolbox::net::StreamSockClnt::get_sock_name ( Endpoint ep)
inline

Definition at line 84 of file StreamSock.hpp.

◆ connect() [1/2]

void toolbox::net::StreamSockClnt::connect ( const Endpoint ep,
std::error_code &  ec 
)
inlinenoexcept

Definition at line 85 of file StreamSock.hpp.

◆ connect() [2/2]

void toolbox::net::StreamSockClnt::connect ( const Endpoint ep)
inline

Definition at line 89 of file StreamSock.hpp.

◆ IoSock()

toolbox::net::IoSock::IoSock ( )
defaultnoexcept

The documentation for this struct was generated from the following file: