diff options
author | Dwayne Boone <dwayne@zeroc.com> | 2006-05-26 15:44:23 +0000 |
---|---|---|
committer | Dwayne Boone <dwayne@zeroc.com> | 2006-05-26 15:44:23 +0000 |
commit | b4d4280b01ee02fd05046b657b06e5fe745becde (patch) | |
tree | ec09f8ccac8b0de03d9efcfac65277529daf225b /cpp/src | |
parent | Updated icon (diff) | |
download | ice-b4d4280b01ee02fd05046b657b06e5fe745becde.tar.bz2 ice-b4d4280b01ee02fd05046b657b06e5fe745becde.tar.xz ice-b4d4280b01ee02fd05046b657b06e5fe745becde.zip |
More changes to inconsistent ice_ proxy methods
Diffstat (limited to 'cpp/src')
-rw-r--r-- | cpp/src/Glacier2/RequestQueue.cpp | 2 | ||||
-rw-r--r-- | cpp/src/Ice/Proxy.cpp | 26 | ||||
-rw-r--r-- | cpp/src/Ice/RouterInfo.cpp | 4 | ||||
-rw-r--r-- | cpp/src/IceGrid/IceGridNode.cpp | 2 | ||||
-rw-r--r-- | cpp/src/IceGrid/InternalRegistryI.cpp | 2 | ||||
-rw-r--r-- | cpp/src/IceGrid/LocatorI.cpp | 2 | ||||
-rw-r--r-- | cpp/src/IceGrid/NodeCache.cpp | 2 | ||||
-rw-r--r-- | cpp/src/IceGrid/RegistryI.cpp | 2 | ||||
-rw-r--r-- | cpp/src/IceGrid/ServerCache.cpp | 4 | ||||
-rw-r--r-- | cpp/src/IceGrid/Topics.cpp | 8 | ||||
-rwxr-xr-x | cpp/src/IcePatch2/ClientUtil.cpp | 3 |
11 files changed, 41 insertions, 16 deletions
diff --git a/cpp/src/Glacier2/RequestQueue.cpp b/cpp/src/Glacier2/RequestQueue.cpp index 7e37ad0ce1f..6554eda8b3b 100644 --- a/cpp/src/Glacier2/RequestQueue.cpp +++ b/cpp/src/Glacier2/RequestQueue.cpp @@ -170,7 +170,7 @@ Glacier2::Request::isBatch() const ConnectionPtr Glacier2::Request::getConnection() const { - return _proxy->ice_connection(); + return _proxy->ice_getConnection(); } Glacier2::Response::Response(const AMD_Array_Object_ice_invokePtr& amdCB, bool ok, diff --git a/cpp/src/Ice/Proxy.cpp b/cpp/src/Ice/Proxy.cpp index 1611c953f29..94e6ce98157 100644 --- a/cpp/src/Ice/Proxy.cpp +++ b/cpp/src/Ice/Proxy.cpp @@ -131,12 +131,24 @@ IceProxy::Ice::Object::operator<(const Object& r) const Int IceProxy::Ice::Object::ice_hash() const { + return ice_getHash(); +} + +Int +IceProxy::Ice::Object::ice_getHash() const +{ return _reference->hash(); } CommunicatorPtr IceProxy::Ice::Object::ice_communicator() const { + return ice_getCommunicator(); +} + +CommunicatorPtr +IceProxy::Ice::Object::ice_getCommunicator() const +{ return _reference->getCommunicator(); } @@ -651,7 +663,7 @@ IceProxy::Ice::Object::ice_locator(const LocatorPrx& locator) const } bool -IceProxy::Ice::Object::ice_getCollocationOptimization() const +IceProxy::Ice::Object::ice_isCollocationOptimized() const { return _reference->getCollocationOptimization(); } @@ -659,6 +671,12 @@ IceProxy::Ice::Object::ice_getCollocationOptimization() const ObjectPrx IceProxy::Ice::Object::ice_collocationOptimization(bool b) const { + return ice_collocationOptimized(b); +} + +ObjectPrx +IceProxy::Ice::Object::ice_collocationOptimized(bool b) const +{ if(b == _reference->getCollocationOptimization()) { return ObjectPrx(const_cast< ::IceProxy::Ice::Object*>(this)); @@ -827,6 +845,12 @@ IceProxy::Ice::Object::ice_connectionId(const string& id) const ConnectionPtr IceProxy::Ice::Object::ice_connection() { + return ice_getConnection(); +} + +ConnectionPtr +IceProxy::Ice::Object::ice_getConnection() +{ int __cnt = 0; while(true) { diff --git a/cpp/src/Ice/RouterInfo.cpp b/cpp/src/Ice/RouterInfo.cpp index c426735b85d..9347ff82c09 100644 --- a/cpp/src/Ice/RouterInfo.cpp +++ b/cpp/src/Ice/RouterInfo.cpp @@ -175,7 +175,7 @@ IceInternal::RouterInfo::getClientProxy() // try { - _clientProxy = _clientProxy->ice_timeout(_router->ice_connection()->timeout()); + _clientProxy = _clientProxy->ice_timeout(_router->ice_getConnection()->timeout()); } catch(const Ice::CollocationOptimizationException&) { @@ -199,7 +199,7 @@ IceInternal::RouterInfo::setClientProxy(const ObjectPrx& clientProxy) // try { - _clientProxy = _clientProxy->ice_timeout(_router->ice_connection()->timeout()); + _clientProxy = _clientProxy->ice_timeout(_router->ice_getConnection()->timeout()); } catch(const Ice::CollocationOptimizationException&) { diff --git a/cpp/src/IceGrid/IceGridNode.cpp b/cpp/src/IceGrid/IceGridNode.cpp index d512c82f6af..9104d68ece5 100644 --- a/cpp/src/IceGrid/IceGridNode.cpp +++ b/cpp/src/IceGrid/IceGridNode.cpp @@ -423,7 +423,7 @@ NodeService::start(int argc, char* argv[]) try { Ice::ObjectPrx object = _adapter->addWithUUID(new FileUserAccountMapperI(userAccountFileProperty)); - object = object->ice_collocationOptimization(true); + object = object->ice_collocationOptimized(true); mapper = UserAccountMapperPrx::uncheckedCast(object); } catch(const std::string& msg) diff --git a/cpp/src/IceGrid/InternalRegistryI.cpp b/cpp/src/IceGrid/InternalRegistryI.cpp index b655a31f4b2..43332e40a1f 100644 --- a/cpp/src/IceGrid/InternalRegistryI.cpp +++ b/cpp/src/IceGrid/InternalRegistryI.cpp @@ -70,7 +70,7 @@ public: } catch(const Ice::LocalException& ex) { - Ice::Warning out(_proxy->ice_communicator()->getLogger()); + Ice::Warning out(_proxy->ice_getCommunicator()->getLogger()); out << "unexpected exception while reaping node session:\n" << ex; } } diff --git a/cpp/src/IceGrid/LocatorI.cpp b/cpp/src/IceGrid/LocatorI.cpp index ddf4efdb535..b51be9e8789 100644 --- a/cpp/src/IceGrid/LocatorI.cpp +++ b/cpp/src/IceGrid/LocatorI.cpp @@ -287,7 +287,7 @@ LocatorI::LocatorI(const Ice::CommunicatorPtr& communicator, const Ice::LocatorRegistryPrx& locatorRegistry) : _communicator(communicator), _database(database), - _locatorRegistry(Ice::LocatorRegistryPrx::uncheckedCast(locatorRegistry->ice_collocationOptimization(false))) + _locatorRegistry(Ice::LocatorRegistryPrx::uncheckedCast(locatorRegistry->ice_collocationOptimized(false))) { } diff --git a/cpp/src/IceGrid/NodeCache.cpp b/cpp/src/IceGrid/NodeCache.cpp index a48dfb956c8..42afc878e0f 100644 --- a/cpp/src/IceGrid/NodeCache.cpp +++ b/cpp/src/IceGrid/NodeCache.cpp @@ -38,7 +38,7 @@ public: Ice::Trace out(_traceLevels->logger, _traceLevels->serverCat); out << "loaded `" << _id << "' on node `" << _node << "'"; } - _server->loadCallback(ServerPrx::uncheckedCast(proxy->ice_collocationOptimization(false)), adapters, at, dt); + _server->loadCallback(ServerPrx::uncheckedCast(proxy->ice_collocationOptimized(false)), adapters, at, dt); } void diff --git a/cpp/src/IceGrid/RegistryI.cpp b/cpp/src/IceGrid/RegistryI.cpp index dedc04e07c5..27a1c73f9fb 100644 --- a/cpp/src/IceGrid/RegistryI.cpp +++ b/cpp/src/IceGrid/RegistryI.cpp @@ -103,7 +103,7 @@ public: } catch(const Ice::LocalException& ex) { - Ice::Warning out(_proxy->ice_communicator()->getLogger()); + Ice::Warning out(_proxy->ice_getCommunicator()->getLogger()); out << "unexpected exception while reaping node session:\n" << ex; } } diff --git a/cpp/src/IceGrid/ServerCache.cpp b/cpp/src/IceGrid/ServerCache.cpp index 5b68c70bc5a..62fdfe8bd33 100644 --- a/cpp/src/IceGrid/ServerCache.cpp +++ b/cpp/src/IceGrid/ServerCache.cpp @@ -605,11 +605,11 @@ ServerEntry::loadCallback(const ServerPrx& proxy, const AdapterPrxDict& adpts, i _loaded = _load; assert(_loaded.get()); int timeout = _cache.getNodeCache().getSessionTimeout() * 1000; // sec to ms - _proxy = ServerPrx::uncheckedCast(proxy->ice_timeout(timeout)->ice_collocationOptimization(false)); + _proxy = ServerPrx::uncheckedCast(proxy->ice_timeout(timeout)->ice_collocationOptimized(false)); _adapters.clear(); for(AdapterPrxDict::const_iterator p = adpts.begin(); p != adpts.end(); ++p) { - Ice::ObjectPrx adapter = p->second->ice_timeout(timeout)->ice_collocationOptimization(false); + Ice::ObjectPrx adapter = p->second->ice_timeout(timeout)->ice_collocationOptimized(false); _adapters.insert(make_pair(p->first, AdapterPrx::uncheckedCast(adapter))); } _activationTimeout = at + timeout; diff --git a/cpp/src/IceGrid/Topics.cpp b/cpp/src/IceGrid/Topics.cpp index c91c87d3490..47795502db5 100644 --- a/cpp/src/IceGrid/Topics.cpp +++ b/cpp/src/IceGrid/Topics.cpp @@ -34,7 +34,7 @@ public: void ice_exception(const Ice::Exception& ex) { - Ice::Warning out(_observer->ice_communicator()->getLogger()); + Ice::Warning out(_observer->ice_getCommunicator()->getLogger()); out << "couldn't initialize registry observer:\n" << ex; } @@ -65,7 +65,7 @@ public: void ice_exception(const Ice::Exception& ex) { - Ice::Warning out(_observer->ice_communicator()->getLogger()); + Ice::Warning out(_observer->ice_getCommunicator()->getLogger()); out << "couldn't initialize node observer:\n" << ex; } @@ -94,7 +94,7 @@ NodeObserverTopic::NodeObserverTopic(const IceStorm::TopicManagerPrx& topicManag // topic because the subscribe() method is given a fixed proxy // which can't be marshalled. // - const_cast<IceStorm::TopicPrx&>(_topic) = IceStorm::TopicPrx::uncheckedCast(t->ice_collocationOptimization(true)); + const_cast<IceStorm::TopicPrx&>(_topic) = IceStorm::TopicPrx::uncheckedCast(t->ice_collocationOptimized(true)); const_cast<NodeObserverPrx&>(_publisher) = NodeObserverPrx::uncheckedCast(_topic->getPublisher()->ice_oneway()); } @@ -261,7 +261,7 @@ RegistryObserverTopic::RegistryObserverTopic(const IceStorm::TopicManagerPrx& to // topic because the subscribe() method is given a fixed proxy // which can't be marshalled. // - const_cast<IceStorm::TopicPrx&>(_topic) = IceStorm::TopicPrx::uncheckedCast(t->ice_collocationOptimization(true)); + const_cast<IceStorm::TopicPrx&>(_topic) = IceStorm::TopicPrx::uncheckedCast(t->ice_collocationOptimized(true)); const_cast<RegistryObserverPrx&>(_publisher) = RegistryObserverPrx::uncheckedCast(_topic->getPublisher()->ice_oneway()); } diff --git a/cpp/src/IcePatch2/ClientUtil.cpp b/cpp/src/IcePatch2/ClientUtil.cpp index 8986ce37723..0cd356e93df 100755 --- a/cpp/src/IcePatch2/ClientUtil.cpp +++ b/cpp/src/IcePatch2/ClientUtil.cpp @@ -591,7 +591,8 @@ IcePatch2::Patcher::init(const FileServerPrx& server) // Make sure that _chunkSize doesn't exceed MessageSizeMax, otherwise // it won't work at all. // - int sizeMax = server->ice_communicator()->getProperties()->getPropertyAsIntWithDefault("Ice.MessageSizeMax", 1024); + int sizeMax = + server->ice_getCommunicator()->getProperties()->getPropertyAsIntWithDefault("Ice.MessageSizeMax", 1024); if(_chunkSize < 1) { const_cast<Int&>(_chunkSize) = 1; |