|
VLink
2.0.0
A high-performance communication middleware
|
Abstract base for every transport-specific configuration aggregate. More...
#include <conf.h>
Public Types | |
| using | PropertiesMap = std::map< std::string, std::string > |
| Key/value property map shared between confs and node implementations. More... | |
Public Member Functions | |
| virtual | ~Conf () |
| Virtual destructor. More... | |
| virtual bool | parse (ImplType impl_type) const |
Validates the conf for impl_type and caches it for subsequent factories. More... | |
| virtual bool | is_valid () const |
| Indicates whether the conf currently holds usable data. More... | |
| virtual ImplType | get_impl_type () const |
Returns the ImplType cached by the most recent parse() call. More... | |
| virtual TransportType | get_transport_type () const |
| Returns the transport backend this conf wraps. More... | |
Public Attributes | |
| uint32_t | hash_code {0} |
| Channel / topic hash assigned by concrete backends. More... | |
Protected Member Functions | |
| Conf () | |
| virtual bool | parse_protocol (struct Protocol *protocol) |
| virtual std::unique_ptr< class ServerImpl > | create_server () const |
| virtual std::unique_ptr< class ClientImpl > | create_client () const |
| virtual std::unique_ptr< class PublisherImpl > | create_publisher () const |
| virtual std::unique_ptr< class SubscriberImpl > | create_subscriber () const |
| virtual std::unique_ptr< class SetterImpl > | create_setter () const |
| virtual std::unique_ptr< class GetterImpl > | create_getter () const |
Friends | |
| struct | Url |
| template<typename , typename , SecurityType > | |
| class | Server |
| template<typename , typename , SecurityType > | |
| class | Client |
| template<typename , SecurityType > | |
| class | Publisher |
| template<typename , SecurityType > | |
| class | Subscriber |
| template<typename , SecurityType > | |
| class | Setter |
| template<typename , SecurityType > | |
| class | Getter |
Abstract base for every transport-specific configuration aggregate.
Holds the cached ImplType selected by parse() and declares the protected factory hooks that the public node templates use to instantiate NodeImpl peers. Default implementations of the factory hooks return nullptr so subclasses only need to override the roles they actually support; combine with VLINK_ALLOW_IMPL_TYPE to make the compile-time guard explicit.
Url and live as long as the node that references them. | using vlink::Conf::PropertiesMap = std::map<std::string, std::string> |
Key/value property map shared between confs and node implementations.
Stores transport tuning entries (e.g. "dds.ip" = "127.0.0.1") that are read by backends during init() and by helpers such as SslOptions.
|
virtual |
Virtual destructor.
|
protected |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
virtual |
Returns the ImplType cached by the most recent parse() call.
ImplType, or kUnknownImplType before parse() runs. Reimplemented in vlink::Url.
|
virtual |
Returns the transport backend this conf wraps.
Default implementation returns TransportType::kUnknown; concrete confs (and dynamic plugins) override it to advertise their backend.
TransportType identifier. Reimplemented in vlink::Url.
|
virtual |
Indicates whether the conf currently holds usable data.
The base implementation returns false; concrete confs override it to verify that mandatory fields have been populated.
true once the conf is ready to drive create_*() factories. Reimplemented in vlink::Url.
|
virtual |
Validates the conf for impl_type and caches it for subsequent factories.
The base implementation rejects kUnknownImplType (the underlying logger call is configured to abort the process) and stores any other value into impl_type_ so that follow-up create_*() calls know the requested role. Subclasses typically chain Conf::parse() and then run their own checks.
| impl_type | Role the caller intends to instantiate. |
true on success; the unknown-type fatal path never returns. Reimplemented in vlink::Url.
|
protectedvirtual |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
| uint32_t vlink::Conf::hash_code {0} |
Channel / topic hash assigned by concrete backends.