mirror of
https://github.com/Telecominfraproject/wlan-cloud-lib-cppkafka.git
synced 2025-11-24 05:34:51 +00:00
Allow building a configuration from an option list
This commit is contained in:
@@ -37,6 +37,7 @@
|
||||
using std::string;
|
||||
using std::map;
|
||||
using std::vector;
|
||||
using std::initializer_list;
|
||||
|
||||
namespace cppkafka {
|
||||
|
||||
@@ -62,6 +63,16 @@ TopicConfiguration::TopicConfiguration()
|
||||
|
||||
}
|
||||
|
||||
TopicConfiguration::TopicConfiguration(const vector<ConfigurationOption>& options)
|
||||
: TopicConfiguration() {
|
||||
set(options);
|
||||
}
|
||||
|
||||
TopicConfiguration::TopicConfiguration(const initializer_list<ConfigurationOption>& options)
|
||||
: TopicConfiguration() {
|
||||
set(options);
|
||||
}
|
||||
|
||||
TopicConfiguration::TopicConfiguration(rd_kafka_topic_conf_t* ptr)
|
||||
: handle_(make_handle(ptr)) {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user