|
VLink
2.0.0
A high-performance communication middleware
|
Transport-neutral base class for every method-model server implementation. More...
#include "./node_impl.h"Go to the source code of this file.
Classes | |
| class | vlink::ServerImpl |
| Method-model server base shared by every transport implementation. More... | |
Namespaces | |
| vlink | |
Transport-neutral base class for every method-model server implementation.
This is an internal implementation header used by the public Server template; applications should depend on server.h. ServerImpl extends NodeImpl with the responder-side bookkeeping: it tracks whether a listen() callback has been installed, whether a response is expected and whether the reply is delivered synchronously inside the request callback or asynchronously via reply().
impl_type with kServer, advertising the role to discovery and recording layers.Server template calls listen() once the user installs a request handler; is_listened becomes true on success.init() / deinit() inherited from NodeImpl bring the transport up.reply() call.| Capability | Provider |
|---|---|
| Request callback registration | Subclass override of listen() |
| Client presence query | Subclass override of has_clients() (optional) |
| Deferred response delivery | Subclass override of reply() for async transports |
| Sync / async behaviour flags | is_resp_type / is_sync_type (set by public layer) |
| Method | Default | Subclass duty |
|---|---|---|
listen(ReqRespCallback&&) | Pure virtual | Bind transport receiver |
has_clients() const | Returns false | Report client presence |
reply(req_id, bytes, is_sync) | Warns on async path | Implement deferred reply |