mirror of
https://github.com/FairRootGroup/FairMQ.git
synced 2025-10-16 10:01:47 +00:00
FairMQ: Implement property change event config API
Replaced the old event manager implementation, which changed the subscription semantics to bulk event subscriptions.
This commit is contained in:
committed by
Mohammad Al-Turany
parent
8c8ee45914
commit
7f23a70670
@@ -91,10 +91,10 @@ class Plugin
|
||||
auto GetPropertyAsString(const std::string& key) const -> std::string { return fPluginServices->GetPropertyAsString(key); }
|
||||
auto GetChannelInfo() const -> std::unordered_map<std::string, int> { return fPluginServices->GetChannelInfo(); }
|
||||
auto GetPropertyKeys() const -> std::vector<std::string> { return fPluginServices->GetPropertyKeys(); }
|
||||
// template<typename T>
|
||||
// auto SubscribeToPropertyChange(std::function<void(const std::string& [>key*/, const T /*newValue<])> callback) const -> void { fPluginServices.SubscribeToPropertyChange(fkName, callback); }
|
||||
// template<typename T>
|
||||
// auto UnsubscribeFromPropertyChange() -> void { fPluginServices.UnsubscribeFromPropertyChange<T>(fkName); }
|
||||
template<typename T>
|
||||
auto SubscribeToPropertyChange(std::function<void(const std::string& key, T newValue)> callback) -> void { fPluginServices->SubscribeToPropertyChange<T>(fkName, callback); }
|
||||
template<typename T>
|
||||
auto UnsubscribeFromPropertyChange() -> void { fPluginServices->UnsubscribeFromPropertyChange<T>(fkName); }
|
||||
|
||||
private:
|
||||
const std::string fkName;
|
||||
|
Reference in New Issue
Block a user