From 93944cf8efcde3080f79088c78d97ff9ea3e6f15 Mon Sep 17 00:00:00 2001 From: Marc Laukien Date: Sun, 25 Nov 2001 15:34:03 +0000 Subject: Blobject --- cpp/src/Ice/Proxy.cpp | 73 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) (limited to 'cpp/src/Ice/Proxy.cpp') diff --git a/cpp/src/Ice/Proxy.cpp b/cpp/src/Ice/Proxy.cpp index b66ebf512b5..82a47527713 100644 --- a/cpp/src/Ice/Proxy.cpp +++ b/cpp/src/Ice/Proxy.cpp @@ -150,6 +150,40 @@ IceProxy::Ice::Object::ice_ping() } } +void +IceProxy::Ice::Object::ice_invokeIn(const string& operation, bool nonmutating, const vector& inParams) +{ + int __cnt = 0; + while (true) + { + try + { + Handle< ::IceDelegate::Ice::Object> __del = __getDelegate(); + __del->ice_invokeIn(operation, inParams); + return; + } + catch (const LocationForward& __ex) + { + __locationForward(__ex); + } + catch (const NonRepeatable& __ex) + { + if (nonmutating) + { + __handleException(*__ex.get(), __cnt); + } + else + { + __rethrowException(*__ex.get()); + } + } + catch (const LocalException& __ex) + { + __handleException(__ex, __cnt); + } + } +} + std::string IceProxy::Ice::Object::ice_getIdentity() const { @@ -497,6 +531,18 @@ IceDelegateM::Ice::Object::ice_ping() } } +void +IceDelegateM::Ice::Object::ice_invokeIn(const string& operation, const vector& inParams) +{ + Outgoing __out(__emitter, __reference, operation.c_str()); + BasicStream* __os = __out.os(); + __os->write(inParams); + if (!__out.invoke()) + { + throw ::Ice::UnknownUserException(__FILE__, __LINE__); + } +} + void IceDelegateM::Ice::Object::ice_flush() { @@ -570,6 +616,33 @@ IceDelegateD::Ice::Object::ice_ping() __direct.facetServant()->ice_ping(); } +void +IceDelegateD::Ice::Object::ice_invokeIn(const string& operation, const vector& inParams) +{ + ::IceInternal::Direct __direct(__adapter, __reference, operation.c_str()); + ::Ice::Blobject* __servant = dynamic_cast< ::Ice::Blobject*>(__direct.facetServant().get()); + if (!__servant) + { + throw ::Ice::OperationNotExistException(__FILE__, __LINE__); + } + try + { + __servant->ice_invokeIn(__reference->identity, __reference->facet, operation, inParams); + } + catch (const ::Ice::LocalException&) + { + throw ::Ice::UnknownLocalException(__FILE__, __LINE__); + } + catch (const ::Ice::UserException&) + { + throw ::Ice::UnknownUserException(__FILE__, __LINE__); + } + catch (...) + { + throw ::Ice::UnknownException(__FILE__, __LINE__); + } +} + void IceDelegateD::Ice::Object::ice_flush() { -- cgit v1.2.3