|
MayaFlux 1.0.0
Digital-First Multimedia Processing Framework
|
StreamBackend policy for Unix domain sockets. More...
#include <UDSBackend.hpp>
Classes | |
| struct | Bound |
Public Types | |
| using | Config = UDSBackendInfo |
| using | Protocol = asio::local::stream_protocol |
| using | Stream = Protocol::socket |
Static Public Member Functions | |
| static std::expected< Bound, std::string > | bind (Protocol::acceptor &acceptor, const EndpointInfo &info) |
| static std::expected< Protocol::endpoint, std::string > | connect_target (const EndpointInfo &info) |
| static std::string | describe (const EndpointInfo &info) |
| static void | describe_accepted (const Protocol::socket &socket, const EndpointInfo &listener, EndpointInfo &accepted) |
| static bool | is_listener (const EndpointInfo &info) |
| static std::string | peer_label (const EndpointInfo &info) |
| static void | release (const Bound &bound) |
Static Public Attributes | |
| static constexpr FramingPolicy | automatic_framing = FramingPolicy::LENGTH_PREFIX |
| static constexpr NetworkTransport | id = NetworkTransport::UDS |
| static constexpr std::string_view | label = "UDS" |
| static constexpr bool | listens = true |
| static constexpr std::string_view | name = "UDS (Asio)" |
StreamBackend policy for Unix domain sockets.
An endpoint with a remote_path connects to it. An endpoint with only a local_path listens on it. A path holding a directory separator is used as given, and a bare file name is placed in the user's runtime directory.
A listener acquires its path before binding: a stale socket file that nothing answers on is replaced, a live one or anything that is not a socket refuses the endpoint. On POSIX the bound file is restricted to its owner, and the file is removed when the listener closes.
Definition at line 22 of file UDSBackend.hpp.