Flow-IPC 1.0.1
Flow-IPC project: Public API.
Classes | Namespaces | Functions
asio_local_stream_socket.hpp File Reference

Classes

class  ipc::transport::asio_local_stream_socket::Opt_peer_process_credentials
 Gettable (read-only) socket option for use with asio_local_stream_socket::Peer_socket .get_option() in order to get the connected opposing peer process's credentials (PID/UID/GID/etc.). More...
 

Namespaces

namespace  ipc
 Catch-all namespace for the Flow-IPC project: A library/API in modern C++17 providing high-performance communication between processes.
 
namespace  ipc::transport
 Flow-IPC module providing transmission of structured messages and/or low-level blobs (and more) between pairs of processes.
 
namespace  ipc::transport::asio_local_stream_socket
 Additional (versus boost.asio) APIs for advanced work with local stream (Unix domain) sockets including transmission of native handles through such streams; and peer process credentials acquisition.
 

Functions

template<typename Task_err >
void ipc::transport::asio_local_stream_socket::async_write_with_native_handle (flow::log::Logger *logger_ptr, Peer_socket *peer_socket, Native_handle payload_hndl, const util::Blob_const &payload_blob, Task_err &&on_sent_or_error)
 boost.asio extension similar to boost::asio::async_write(Peer_socket&, Blob_const, Task_err_sz) with the added capability of accompanying the Blob_const with a native handle to be transmitted to the opposing peer. More...
 
template<typename Task_err_blob , typename Target_payload_blob_func , typename Should_interrupt_func >
void ipc::transport::asio_local_stream_socket::async_read_with_target_func (flow::log::Logger *logger_ptr, Peer_socket *peer_socket, Target_payload_blob_func &&target_payload_blob_func, Should_interrupt_func &&should_interrupt_func, Task_err_blob &&on_rcvd_or_error)
 boost.asio extension similar to boost::asio::async_read(Peer_socket&, Blob_mutable, Task_err_sz) with the difference that the target buffer (util::Blob_mutable) is determined by calling the arg-supplied function at the time when at least 1 byte is available to read, instead of the buffer being given direcly as an arg. More...
 
template<typename Task_err , typename Should_interrupt_func >
void ipc::transport::asio_local_stream_socket::async_read_interruptible (flow::log::Logger *logger_ptr, Peer_socket *peer_socket, util::Blob_mutable target_payload_blob, Should_interrupt_func &&should_interrupt_func, Task_err &&on_rcvd_or_error)
 boost.asio extension similar to boost::asio::async_read(Peer_socket&, Blob_mutable, Task_err_sz) with the difference that it can be canceled/interrupted via should_interrupt_func() in the same way as the otherwise more complex async_read_with_target_func(). More...