diff options
author | Marc Laukien <marc@zeroc.com> | 2001-10-14 17:58:55 +0000 |
---|---|---|
committer | Marc Laukien <marc@zeroc.com> | 2001-10-14 17:58:55 +0000 |
commit | 5c872d29b6223e23daea5b510a2bcb4d43fa08eb (patch) | |
tree | e4e7f5a7f43a76c7cee0a52626b2a1c294763bb9 /cpp/src/Ice/CommunicatorI.cpp | |
parent | fixes (diff) | |
download | ice-5c872d29b6223e23daea5b510a2bcb4d43fa08eb.tar.bz2 ice-5c872d29b6223e23daea5b510a2bcb4d43fa08eb.tar.xz ice-5c872d29b6223e23daea5b510a2bcb4d43fa08eb.zip |
user exceptin factories
Diffstat (limited to 'cpp/src/Ice/CommunicatorI.cpp')
-rw-r--r-- | cpp/src/Ice/CommunicatorI.cpp | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/cpp/src/Ice/CommunicatorI.cpp b/cpp/src/Ice/CommunicatorI.cpp index 78a149ba5c1..05d7165634e 100644 --- a/cpp/src/Ice/CommunicatorI.cpp +++ b/cpp/src/Ice/CommunicatorI.cpp @@ -14,6 +14,7 @@ #include <Ice/ProxyFactory.h> #include <Ice/ThreadPool.h> #include <Ice/ServantFactoryManager.h> +#include <Ice/UserExceptionFactoryManager.h> #include <Ice/ObjectAdapterFactory.h> #include <Ice/Logger.h> #include <Ice/StreamI.h> @@ -135,6 +136,39 @@ Ice::CommunicatorI::findServantFactory(const string& id) return _instance->servantFactoryManager()->find(id); } +void +Ice::CommunicatorI::addUserExceptionFactory(const UserExceptionFactoryPtr& factory, const string& id) +{ + JTCSyncT<JTCRecursiveMutex> sync(*this); + if (!_instance) + { + throw CommunicatorDestroyedException(__FILE__, __LINE__); + } + _instance->userExceptionFactoryManager()->add(factory, id); +} + +void +Ice::CommunicatorI::removeUserExceptionFactory(const string& id) +{ + JTCSyncT<JTCRecursiveMutex> sync(*this); + if (!_instance) + { + throw CommunicatorDestroyedException(__FILE__, __LINE__); + } + _instance->userExceptionFactoryManager()->remove(id); +} + +UserExceptionFactoryPtr +Ice::CommunicatorI::findUserExceptionFactory(const string& id) +{ + JTCSyncT<JTCRecursiveMutex> sync(*this); + if (!_instance) + { + throw CommunicatorDestroyedException(__FILE__, __LINE__); + } + return _instance->userExceptionFactoryManager()->find(id); +} + PropertiesPtr Ice::CommunicatorI::getProperties() { |