summaryrefslogtreecommitdiff
path: root/cpp/src/qpid/broker/ExchangeRegistry.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/src/qpid/broker/ExchangeRegistry.cpp')
-rw-r--r--cpp/src/qpid/broker/ExchangeRegistry.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/cpp/src/qpid/broker/ExchangeRegistry.cpp b/cpp/src/qpid/broker/ExchangeRegistry.cpp
index 45eb308680..309e88e8be 100644
--- a/cpp/src/qpid/broker/ExchangeRegistry.cpp
+++ b/cpp/src/qpid/broker/ExchangeRegistry.cpp
@@ -97,6 +97,10 @@ Exchange::shared_ptr ExchangeRegistry::get(const string& name){
return i->second;
}
+bool ExchangeRegistry::registerExchange(const Exchange::shared_ptr& ex) {
+ return exchanges.insert(ExchangeMap::value_type(ex->getName(), ex)).second;
+}
+
void ExchangeRegistry::registerType(const std::string& type, FactoryFunction f)
{
factory[type] = f;