|
contur2
|
Common interface for IPC channels. More...
#include <i_ipc_channel.h>

Public Member Functions | |
| virtual | ~IIpcChannel ()=default |
| virtual Result< std::size_t > | write (std::span< const std::byte > data)=0 |
| Writes up to data.size() bytes into the channel. | |
| virtual Result< std::size_t > | read (std::span< std::byte > buffer)=0 |
| Reads up to buffer.size() bytes from the channel. | |
| virtual void | close ()=0 |
| Closes the channel and releases transient state. | |
| virtual bool | isOpen () const noexcept=0 |
| Returns whether the channel accepts read/write operations. | |
| virtual std::string_view | name () const noexcept=0 |
| Human-readable channel name. | |
Common interface for IPC channels.
Implementations provide byte-level read/write semantics and lifecycle control through open/close state.
Definition at line 18 of file i_ipc_channel.h.
|
virtualdefault |
|
pure virtual |
Closes the channel and releases transient state.
Implemented in contur::MessageQueue, contur::Pipe, and contur::SharedMemory.
|
nodiscardpure virtualnoexcept |
Returns whether the channel accepts read/write operations.
Implemented in contur::MessageQueue, contur::Pipe, and contur::SharedMemory.
|
nodiscardpure virtualnoexcept |
Human-readable channel name.
Implemented in contur::MessageQueue, contur::Pipe, and contur::SharedMemory.
|
nodiscardpure virtual |
Reads up to buffer.size() bytes from the channel.
| buffer | Destination buffer. |
Implemented in contur::MessageQueue, contur::Pipe, and contur::SharedMemory.
|
nodiscardpure virtual |
Writes up to data.size() bytes into the channel.
| data | Source bytes. |
Implemented in contur::MessageQueue, contur::Pipe, and contur::SharedMemory.