![]() |
Contur 2
Educational OS kernel simulator
|
Registry/mediator for named IPC channels. More...
#include <ipc_manager.h>
Public Member Functions | |
| IpcManager () | |
| Constructs empty IPC channel registry. | |
| ~IpcManager () | |
| Destroys registry and all owned channels. | |
| IpcManager (const IpcManager &)=delete | |
| Copy construction is disabled. | |
| IpcManager & | operator= (const IpcManager &)=delete |
| Copy assignment is disabled. | |
| IpcManager (IpcManager &&) noexcept | |
| Move-constructs registry state. | |
| IpcManager & | operator= (IpcManager &&) noexcept |
| Move-assigns registry state. | |
| Result< void > | createPipe (const std::string &name, std::size_t capacity=1024) |
| Creates a pipe channel if it does not already exist. | |
| Result< void > | createSharedMemory (const std::string &name, std::size_t bytes) |
| Creates a shared-memory channel if it does not already exist. | |
| Result< void > | createMessageQueue (const std::string &name, std::size_t maxMessages=64, bool priorityMode=false) |
| Creates a message queue channel if it does not already exist. | |
| Result< std::reference_wrapper< IIpcChannel > > | getChannel (const std::string &name) |
| Looks up a channel by name. | |
| Result< void > | destroyChannel (const std::string &name) |
| Destroys a channel by name. | |
| bool | exists (const std::string &name) const noexcept |
| Checks whether a named channel exists. | |
| std::size_t | channelCount () const noexcept |
| Number of registered channels. | |
Private Attributes | |
| std::unique_ptr< Impl > | impl_ |
Registry/mediator for named IPC channels.
IpcManager owns channel lifetimes and provides lookup by name.
Definition at line 17 of file ipc_manager.h.
| contur::IpcManager::IpcManager | ( | ) |
Constructs empty IPC channel registry.
Referenced by IpcManager(), IpcManager(), operator=(), and operator=().
| contur::IpcManager::~IpcManager | ( | ) |
Destroys registry and all owned channels.
|
delete |
Copy construction is disabled.
References IpcManager().
|
noexcept |
Move-constructs registry state.
References IpcManager().
|
nodiscardnoexcept |
|
nodiscard |
Creates a message queue channel if it does not already exist.
| name | Channel name. |
| maxMessages | Maximum queued messages. |
| priorityMode | True enables priority ordering. |
References createMessageQueue().
Referenced by createMessageQueue().
|
nodiscard |
Creates a pipe channel if it does not already exist.
| name | Channel name. |
| capacity | Pipe capacity in bytes. |
References createPipe().
Referenced by createPipe().
|
nodiscard |
Creates a shared-memory channel if it does not already exist.
| name | Channel name. |
| bytes | Shared-memory size in bytes. |
References createSharedMemory().
Referenced by createSharedMemory().
|
nodiscard |
Destroys a channel by name.
References destroyChannel().
Referenced by destroyChannel().
|
nodiscardnoexcept |
|
nodiscard |
Looks up a channel by name.
References getChannel().
Referenced by getChannel().
|
delete |
Copy assignment is disabled.
References IpcManager().
|
noexcept |
Move-assigns registry state.
References IpcManager().
|
private |
Definition at line 73 of file ipc_manager.h.