diff options
author | Jose <jose@zeroc.com> | 2015-12-09 23:09:20 +0100 |
---|---|---|
committer | Jose <jose@zeroc.com> | 2015-12-09 23:09:20 +0100 |
commit | a00673a2c1d9634102f91b7c6ebdd453d55a708f (patch) | |
tree | 2097f43ff5a1516b353ed0e88cc7b4174a518a17 /cpp | |
parent | Windows build fixes (diff) | |
download | ice-a00673a2c1d9634102f91b7c6ebdd453d55a708f.tar.bz2 ice-a00673a2c1d9634102f91b7c6ebdd453d55a708f.tar.xz ice-a00673a2c1d9634102f91b7c6ebdd453d55a708f.zip |
C++11 mapping server side input parameter fixes
Diffstat (limited to 'cpp')
50 files changed, 1109 insertions, 788 deletions
diff --git a/cpp/include/Ice/MetricsAdminI.h b/cpp/include/Ice/MetricsAdminI.h index bd58a673435..5ce78e054fc 100644 --- a/cpp/include/Ice/MetricsAdminI.h +++ b/cpp/include/Ice/MetricsAdminI.h @@ -645,6 +645,14 @@ public: void unregisterMap(const std::string&); virtual Ice::StringSeq getMetricsViewNames(Ice::StringSeq&, const ::Ice::Current&); + +#ifdef ICE_CPP11_MAPPING + virtual void enableMetricsView(std::string, const ::Ice::Current&); + virtual void disableMetricsView(std::string, const ::Ice::Current&); + virtual IceMX::MetricsView getMetricsView(std::string, Ice::Long&, const ::Ice::Current&); + virtual IceMX::MetricsFailuresSeq getMapMetricsFailures(std::string, std::string, const ::Ice::Current&); + virtual IceMX::MetricsFailures getMetricsFailures(std::string, std::string, std::string, const ::Ice::Current&); +#else virtual void enableMetricsView(const std::string&, const ::Ice::Current&); virtual void disableMetricsView(const std::string&, const ::Ice::Current&); virtual IceMX::MetricsView getMetricsView(const std::string&, Ice::Long&, const ::Ice::Current&); @@ -652,7 +660,7 @@ public: const ::Ice::Current&); virtual IceMX::MetricsFailures getMetricsFailures(const std::string&, const std::string&, const std::string&, const ::Ice::Current&); - +#endif std::vector<MetricsMapIPtr> getMaps(const std::string&) const; const Ice::LoggerPtr& getLogger() const; diff --git a/cpp/include/Slice/CPlusPlusUtil.h b/cpp/include/Slice/CPlusPlusUtil.h index 413a855e2d3..ab0a0c6f2fb 100644 --- a/cpp/include/Slice/CPlusPlusUtil.h +++ b/cpp/include/Slice/CPlusPlusUtil.h @@ -35,6 +35,7 @@ const int TypeContextAMICallPrivateEnd = 8; const int TypeContextUseWstring = 16; const int TypeContextReadClosure = 32; const int TypeContextLocalOperation = 64; +const int TypeContextAMD = 128; SLICE_API bool isMovable(const TypePtr&); diff --git a/cpp/src/Ice/Instance.cpp b/cpp/src/Ice/Instance.cpp index 4952c61d152..e94431d3a2d 100644 --- a/cpp/src/Ice/Instance.cpp +++ b/cpp/src/Ice/Instance.cpp @@ -1951,7 +1951,11 @@ IceInternal::ProcessI::shutdown(const Current&) } void +#ifdef ICE_CPP11_MAPPING +IceInternal::ProcessI::writeMessage(string message, Int fd, const Current&) +#else IceInternal::ProcessI::writeMessage(const string& message, Int fd, const Current&) +#endif { switch(fd) { diff --git a/cpp/src/Ice/Instance.h b/cpp/src/Ice/Instance.h index 2f352cc61dd..05b235c303b 100644 --- a/cpp/src/Ice/Instance.h +++ b/cpp/src/Ice/Instance.h @@ -212,7 +212,11 @@ public: ProcessI(const Ice::CommunicatorPtr&); virtual void shutdown(const Ice::Current&); +#ifdef ICE_CPP11_MAPPING + virtual void writeMessage(std::string, Ice::Int, const Ice::Current&); +#else virtual void writeMessage(const std::string&, Ice::Int, const Ice::Current&); +#endif private: diff --git a/cpp/src/Ice/LoggerAdminI.cpp b/cpp/src/Ice/LoggerAdminI.cpp index 64c68dee606..86b820f27eb 100644 --- a/cpp/src/Ice/LoggerAdminI.cpp +++ b/cpp/src/Ice/LoggerAdminI.cpp @@ -33,12 +33,21 @@ public: LoggerAdminI(const PropertiesPtr&); - virtual void attachRemoteLogger(const RemoteLoggerPrxPtr&, const LogMessageTypeSeq&, +#ifdef ICE_CPP11_MAPPING + virtual void attachRemoteLogger(shared_ptr<RemoteLoggerPrx>, LogMessageTypeSeq, + StringSeq, Int, const Current&); + + virtual bool detachRemoteLogger(shared_ptr<RemoteLoggerPrx>, const Current&); + + virtual LogMessageSeq getLog(LogMessageTypeSeq, StringSeq, Int, string&, const Current&); +#else + virtual void attachRemoteLogger(const RemoteLoggerPrx&, const LogMessageTypeSeq&, const StringSeq&, Int, const Current&); - virtual bool detachRemoteLogger(const RemoteLoggerPrxPtr&, const Current&); + virtual bool detachRemoteLogger(const RemoteLoggerPrx&, const Current&); virtual LogMessageSeq getLog(const LogMessageTypeSeq&, const StringSeq&, Int, string&, const Current&); +#endif void destroy(); @@ -324,11 +333,19 @@ LoggerAdminI::LoggerAdminI(const PropertiesPtr& props) : } void -LoggerAdminI::attachRemoteLogger(const RemoteLoggerPrxPtr& prx, +#ifdef ICE_CPP11_MAPPING +LoggerAdminI::attachRemoteLogger(shared_ptr<RemoteLoggerPrx> prx, + LogMessageTypeSeq messageTypes, + StringSeq categories, + Int messageMax, + const Current& current) +#else +LoggerAdminI::attachRemoteLogger(const RemoteLoggerPrx& prx, const LogMessageTypeSeq& messageTypes, const StringSeq& categories, Int messageMax, const Current& current) +#endif { if(!prx) { @@ -438,7 +455,11 @@ LoggerAdminI::attachRemoteLogger(const RemoteLoggerPrxPtr& prx, } bool -LoggerAdminI::detachRemoteLogger(const RemoteLoggerPrxPtr& remoteLogger, const Current& current) +#ifdef ICE_CPP11_MAPPING +LoggerAdminI::detachRemoteLogger(shared_ptr<RemoteLoggerPrx> remoteLogger, const Current& current) +#else +LoggerAdminI::detachRemoteLogger(const RemoteLoggerPrx& remoteLogger, const Current& current) +#endif { if(remoteLogger == 0) { @@ -467,8 +488,13 @@ LoggerAdminI::detachRemoteLogger(const RemoteLoggerPrxPtr& remoteLogger, const C } LogMessageSeq -LoggerAdminI::getLog(const LogMessageTypeSeq& messageTypes, const StringSeq& categories, +#ifdef ICE_CPP11_MAPPING +LoggerAdminI::getLog(LogMessageTypeSeq messageTypes, StringSeq categories, + Int messageMax, string& prefix, const Current& current) +#else +LoggerAdminI::getLog(LogMessageTypeSeq messageTypes, StringSeq categories, Int messageMax, string& prefix, const Current& current) +#endif { LogMessageSeq logMessages; { diff --git a/cpp/src/Ice/MetricsAdminI.cpp b/cpp/src/Ice/MetricsAdminI.cpp index a80e1a7c3ab..0fa85ff3c4f 100644 --- a/cpp/src/Ice/MetricsAdminI.cpp +++ b/cpp/src/Ice/MetricsAdminI.cpp @@ -529,7 +529,11 @@ MetricsAdminI::getMetricsViewNames(Ice::StringSeq& disabledViews, const Current& } void +#ifdef ICE_CPP11_MAPPING +MetricsAdminI::enableMetricsView(string viewName, const Current&) +#else MetricsAdminI::enableMetricsView(const string& viewName, const Current&) +#endif { { Lock sync(*this); @@ -540,7 +544,11 @@ MetricsAdminI::enableMetricsView(const string& viewName, const Current&) } void +#ifdef ICE_CPP11_MAPPING +MetricsAdminI::disableMetricsView(string viewName, const Current&) +#else MetricsAdminI::disableMetricsView(const string& viewName, const Current&) +#endif { { Lock sync(*this); @@ -551,7 +559,11 @@ MetricsAdminI::disableMetricsView(const string& viewName, const Current&) } MetricsView +#ifdef ICE_CPP11_MAPPING +MetricsAdminI::getMetricsView(string viewName, ::Ice::Long& timestamp, const Current&) +#else MetricsAdminI::getMetricsView(const string& viewName, ::Ice::Long& timestamp, const Current&) +#endif { Lock sync(*this); MetricsViewIPtr view = getMetricsView(viewName); @@ -564,7 +576,11 @@ MetricsAdminI::getMetricsView(const string& viewName, ::Ice::Long& timestamp, co } MetricsFailuresSeq +#ifdef ICE_CPP11_MAPPING +MetricsAdminI::getMapMetricsFailures(string viewName, string map, const Current&) +#else MetricsAdminI::getMapMetricsFailures(const string& viewName, const string& map, const Current&) +#endif { Lock sync(*this); MetricsViewIPtr view = getMetricsView(viewName); @@ -576,7 +592,11 @@ MetricsAdminI::getMapMetricsFailures(const string& viewName, const string& map, } MetricsFailures +#ifdef ICE_CPP11_MAPPING +MetricsAdminI::getMetricsFailures(string viewName, string map, string id, const Current&) +#else MetricsAdminI::getMetricsFailures(const string& viewName, const string& map, const string& id, const Current&) +#endif { Lock sync(*this); MetricsViewIPtr view = getMetricsView(viewName); diff --git a/cpp/src/Ice/Object.cpp b/cpp/src/Ice/Object.cpp index 14086c0d81b..24ba8ea42b7 100644 --- a/cpp/src/Ice/Object.cpp +++ b/cpp/src/Ice/Object.cpp @@ -96,7 +96,11 @@ Ice::Object::___ice_isA(Incoming& __inS, const Current& __current) string __id; __is->read(__id, false); __inS.endReadParams(); +#ifdef ICE_CPP11_MAPPING + bool __ret = ice_isA(move(__id), __current); +#else bool __ret = ice_isA(__id, __current); +#endif BasicStream* __os = __inS.__startWriteParams(DefaultFormat); __os->write(__ret); __inS.__endWriteParams(true); diff --git a/cpp/src/Ice/PropertiesAdminI.cpp b/cpp/src/Ice/PropertiesAdminI.cpp index 4cd90f614ba..bcf0370c245 100644 --- a/cpp/src/Ice/PropertiesAdminI.cpp +++ b/cpp/src/Ice/PropertiesAdminI.cpp @@ -30,14 +30,22 @@ PropertiesAdminI::PropertiesAdminI(const PropertiesPtr& properties, const Logger } string +#ifdef ICE_CPP11_MAPPING +PropertiesAdminI::getProperty(string name, const Current&) +#else PropertiesAdminI::getProperty(const string& name, const Current&) +#endif { Lock sync(*this); return _properties->getProperty(name); } PropertyDict +#ifdef ICE_CPP11_MAPPING +PropertiesAdminI::getPropertiesForPrefix(string prefix, const Current&) +#else PropertiesAdminI::getPropertiesForPrefix(const string& prefix, const Current&) +#endif { Lock sync(*this); return _properties->getPropertiesForPrefix(prefix); @@ -45,9 +53,9 @@ PropertiesAdminI::getPropertiesForPrefix(const string& prefix, const Current&) void #ifdef ICE_CPP11_MAPPING -PropertiesAdminI::setProperties_async(const PropertyDict& props, +PropertiesAdminI::setProperties_async(PropertyDict props, function<void ()> response, - function<void (const ::std::exception_ptr&)>, + function<void (exception_ptr)>, const Current&) #else PropertiesAdminI::setProperties_async(const AMD_PropertiesAdmin_setPropertiesPtr& cb, const PropertyDict& props, diff --git a/cpp/src/Ice/PropertiesAdminI.h b/cpp/src/Ice/PropertiesAdminI.h index 789a6aee6d5..4f23521e399 100644 --- a/cpp/src/Ice/PropertiesAdminI.h +++ b/cpp/src/Ice/PropertiesAdminI.h @@ -25,13 +25,16 @@ public: PropertiesAdminI(const Ice::PropertiesPtr&, const Ice::LoggerPtr&); - virtual std::string getProperty(const std::string&, const Ice::Current&); - virtual Ice::PropertyDict getPropertiesForPrefix(const std::string&, const Ice::Current&); - #ifdef ICE_CPP11_MAPPING - virtual void setProperties_async(const ::Ice::PropertyDict&, ::std::function<void ()>, - ::std::function<void (const ::std::exception_ptr&)>, const Ice::Current&); + virtual std::string getProperty(std::string, const Ice::Current&); + virtual Ice::PropertyDict getPropertiesForPrefix(std::string, const Ice::Current&); + virtual void setProperties_async(::Ice::PropertyDict, + ::std::function<void ()>, + ::std::function<void (::std::exception_ptr)>, + const Ice::Current&); #else + virtual std::string getProperty(const std::string&, const Ice::Current&); + virtual Ice::PropertyDict getPropertiesForPrefix(const std::string&, const Ice::Current&); virtual void setProperties_async(const Ice::AMD_PropertiesAdmin_setPropertiesPtr&, const Ice::PropertyDict&, const Ice::Current&); #endif diff --git a/cpp/src/IceDiscovery/LocatorI.cpp b/cpp/src/IceDiscovery/LocatorI.cpp index fe7b6122115..cc7fbc70ef2 100644 --- a/cpp/src/IceDiscovery/LocatorI.cpp +++ b/cpp/src/IceDiscovery/LocatorI.cpp @@ -26,10 +26,10 @@ LocatorRegistryI::LocatorRegistryI(const Ice::CommunicatorPtr& com) : #ifdef ICE_CPP11_MAPPING void -LocatorRegistryI::setAdapterDirectProxy_async(const string& adapterId, - const shared_ptr<ObjectPrx>& proxy, +LocatorRegistryI::setAdapterDirectProxy_async(string adapterId, + shared_ptr<ObjectPrx> proxy, function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) #else void @@ -57,11 +57,11 @@ LocatorRegistryI::setAdapterDirectProxy_async(const AMD_LocatorRegistry_setAdapt #ifdef ICE_CPP11_MAPPING void -LocatorRegistryI::setReplicatedAdapterDirectProxy_async(const string& adapterId, - const string& replicaGroupId, - const shared_ptr<ObjectPrx>& proxy, +LocatorRegistryI::setReplicatedAdapterDirectProxy_async(string adapterId, + string replicaGroupId, + shared_ptr<ObjectPrx> proxy, function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) #else void @@ -106,10 +106,10 @@ LocatorRegistryI::setReplicatedAdapterDirectProxy_async( #ifdef ICE_CPP11_MAPPING void -LocatorRegistryI::setServerProcessProxy_async(const string&, - const shared_ptr<ProcessPrx>&, +LocatorRegistryI::setServerProcessProxy_async(string, + shared_ptr<ProcessPrx>, function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(); @@ -226,18 +226,18 @@ LocatorI::LocatorI(const LookupIPtr& lookup, const LocatorRegistryPrxPtr& regist #ifdef ICE_CPP11_MAPPING void -LocatorI::findObjectById_async(const Ice::Identity& id, +LocatorI::findObjectById_async(Ice::Identity id, function<void (const shared_ptr<ObjectPrx>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) const { _lookup->findObject(response, id); } void -LocatorI::findAdapterById_async(const std::string& adapterId, +LocatorI::findAdapterById_async(string adapterId, function<void (const shared_ptr<ObjectPrx>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) const { _lookup->findAdapter(response, adapterId); diff --git a/cpp/src/IceDiscovery/LocatorI.h b/cpp/src/IceDiscovery/LocatorI.h index 9bc375b6495..bf09b88a665 100644 --- a/cpp/src/IceDiscovery/LocatorI.h +++ b/cpp/src/IceDiscovery/LocatorI.h @@ -26,24 +26,25 @@ public: #ifdef ICE_CPP11_MAPPING virtual void - setAdapterDirectProxy_async(const std::string&, - const std::shared_ptr<Ice::ObjectPrx>&, + setAdapterDirectProxy_async(std::string, + std::shared_ptr<Ice::ObjectPrx>, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void - setReplicatedAdapterDirectProxy_async(const std::string&, const std::string&, - const std::shared_ptr<Ice::ObjectPrx>&, + setReplicatedAdapterDirectProxy_async(std::string, + std::string, + std::shared_ptr<Ice::ObjectPrx>, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void - setServerProcessProxy_async(const std::string&, - const std::shared_ptr<Ice::ProcessPrx>&, + setServerProcessProxy_async(std::string, + std::shared_ptr<Ice::ProcessPrx>, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); #else virtual void @@ -81,15 +82,15 @@ public: #ifdef ICE_CPP11_MAPPING virtual void - findObjectById_async(const Ice::Identity&, + findObjectById_async(Ice::Identity, std::function<void (const std::shared_ptr<Ice::ObjectPrx>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&) const; virtual void - findAdapterById_async(const std::string&, + findAdapterById_async(std::string, std::function<void (const std::shared_ptr<Ice::ObjectPrx>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&) const; #else virtual void diff --git a/cpp/src/IceDiscovery/LookupI.cpp b/cpp/src/IceDiscovery/LookupI.cpp index d44a97f287a..d7e9ef7b1fa 100644 --- a/cpp/src/IceDiscovery/LookupI.cpp +++ b/cpp/src/IceDiscovery/LookupI.cpp @@ -179,8 +179,13 @@ LookupI::setLookupReply(const LookupReplyPrxPtr& lookupReply) } void -LookupI::findObjectById(const string& domainId, const Ice::Identity& id, const IceDiscovery::LookupReplyPrxPtr& reply, +#ifdef ICE_CPP11_MAPPING +LookupI::findObjectById(string domainId, Ice::Identity id, shared_ptr<IceDiscovery::LookupReplyPrx> reply, + const Ice::Current&) +#else +LookupI::findObjectById(const string& domainId, const Ice::Identity& id, const IceDiscovery::LookupReplyPrx& reply, const Ice::Current&) +#endif { if(domainId != _domainId) { @@ -209,8 +214,13 @@ LookupI::findObjectById(const string& domainId, const Ice::Identity& id, const I } void -LookupI::findAdapterById(const string& domainId, const std::string& adapterId, - const IceDiscovery::LookupReplyPrxPtr& reply, const Ice::Current&) +#ifdef ICE_CPP11_MAPPING +LookupI::findAdapterById(string domainId, string adapterId, shared_ptr<IceDiscovery::LookupReplyPrx> reply, + const Ice::Current&) +#else +LookupI::findAdapterById(const string& domainId, const string& adapterId, const IceDiscovery::LookupReplyPrxPtr& reply, + const Ice::Current&) +#endif { if(domainId != _domainId) { @@ -441,16 +451,28 @@ LookupReplyI::LookupReplyI(const LookupIPtr& lookup) : _lookup(lookup) { } +#ifdef ICE_CPP11_MAPPING void -LookupReplyI::foundObjectById(const Ice::Identity& id, const Ice::ObjectPrxPtr& proxy, const Ice::Current&) +LookupReplyI::foundObjectById(Identity id, shared_ptr<ObjectPrx> proxy, const Current&) { _lookup->foundObject(id, proxy); } void -LookupReplyI::foundAdapterById(const std::string& adapterId, const Ice::ObjectPrxPtr& proxy, bool isReplicaGroup, - const Ice::Current&) +LookupReplyI::foundAdapterById(string adapterId, shared_ptr<ObjectPrx> proxy, bool isReplicaGroup, const Current&) { _lookup->foundAdapter(adapterId, proxy, isReplicaGroup); } +#else +void +LookupReplyI::foundObjectById(const Identity& id, const ObjectPrxPtr& proxy, const Current&) +{ + _lookup->foundObject(id, proxy); +} +void +LookupReplyI::foundAdapterById(const string& adapterId, const ObjectPrxPtr& proxy, bool isReplicaGroup, const Current&) +{ + _lookup->foundAdapter(adapterId, proxy, isReplicaGroup); +} +#endif diff --git a/cpp/src/IceDiscovery/LookupI.h b/cpp/src/IceDiscovery/LookupI.h index ad242f0d6d0..b54875ff0f2 100644 --- a/cpp/src/IceDiscovery/LookupI.h +++ b/cpp/src/IceDiscovery/LookupI.h @@ -216,22 +216,27 @@ public: void setLookupReply(const LookupReplyPrxPtr&); - virtual void findObjectById(const std::string&, const Ice::Identity&, const IceDiscovery::LookupReplyPrxPtr&, +#ifdef ICE_CPP11_MAPPING + virtual void findObjectById(std::string, + Ice::Identity, + ::std::shared_ptr<IceDiscovery::LookupReplyPrx>, const Ice::Current&); - virtual void findAdapterById(const std::string&, const std::string&, const IceDiscovery::LookupReplyPrxPtr&, + virtual void findAdapterById(std::string, std::string, ::std::shared_ptr<IceDiscovery::LookupReplyPrx>, const Ice::Current&); - -#ifdef ICE_CPP11_MAPPING void findObject(std::function<void (const std::shared_ptr<Ice::ObjectPrx>&)>, const Ice::Identity&); void findAdapter(std::function<void (const std::shared_ptr<Ice::ObjectPrx>&)>, const std::string&); #else + virtual void findObjectById(const std::string&, const Ice::Identity&, const IceDiscovery::LookupReplyPrx&, + const Ice::Current&); + virtual void findAdapterById(const std::string&, const std::string, ::std::shared_ptr<IceDiscovery::LookupReplyPrx>, + const Ice::Current&); void findObject(const Ice::AMD_Locator_findObjectByIdPtr&, const Ice::Identity&); void findAdapter(const Ice::AMD_Locator_findAdapterByIdPtr&, const std::string&); #endif void foundObject(const Ice::Identity&, const Ice::ObjectPrxPtr&); void foundAdapter(const std::string&, const Ice::ObjectPrxPtr&, bool); - + void adapterRequestTimedOut(const AdapterRequestPtr&); void objectRequestTimedOut(const ObjectRequestPtr&); @@ -270,8 +275,13 @@ public: LookupReplyI(const LookupIPtr&); - virtual void foundObjectById(const Ice::Identity&, const Ice::ObjectPrxPtr&, const Ice::Current&); - virtual void foundAdapterById(const std::string&, const Ice::ObjectPrxPtr&, bool, const Ice::Current&); +#ifdef ICE_CPP11_MAPPING + virtual void foundObjectById(Ice::Identity, std::shared_ptr<Ice::ObjectPrx>, const Ice::Current&); + virtual void foundAdapterById(std::string, std::shared_ptr<Ice::ObjectPrx>, bool, const Ice::Current&); +#else + virtual void foundObjectById(const Ice::Identity&, const Ice::ObjectPrx&, const Ice::Current&); + virtual void foundAdapterById(const std::string&, const Ice::ObjectPrx&, bool, const Ice::Current&); +#endif private: diff --git a/cpp/src/Slice/CPlusPlusUtil.cpp b/cpp/src/Slice/CPlusPlusUtil.cpp index bc61ca61fe3..bfc21c2cb46 100644 --- a/cpp/src/Slice/CPlusPlusUtil.cpp +++ b/cpp/src/Slice/CPlusPlusUtil.cpp @@ -662,7 +662,7 @@ Slice::returnTypeToString(const TypePtr& type, bool optional, const StringList& string Slice::inputTypeToString(const TypePtr& type, bool optional, const StringList& metaData, int typeCtx, bool cpp11) { - static const char* inputBuiltinTable[] = + static const char* cpp98InputBuiltinTable[] = { "::Ice::Byte", "bool", @@ -678,27 +678,52 @@ Slice::inputTypeToString(const TypePtr& type, bool optional, const StringList& m "const ::Ice::ValuePtr&" }; - static const char* cpp11InputBuiltinTable[] = - { - "::Ice::Byte", - "bool", - "short", - "int", - "long long int", - "float", - "double", - "const ::std::string&", - "const ::std::shared_ptr<::Ice::Object>&", - "const ::std::shared_ptr<::Ice::ObjectPrx>&", - "const ::std::shared_ptr<void>&", - "const ::std::shared_ptr<::Ice::Value>&" - }; + static const char* cpp11InputLocalBuiltinTable[] = + { + "::Ice::Byte", + "bool", + "short", + "int", + "long long int", + "float", + "double", + "const ::std::string&", + "const ::std::shared_ptr<::Ice::Object>&", + "const ::std::shared_ptr<::Ice::ObjectPrx>&", + "const ::std::shared_ptr<void>&", + "const ::std::shared_ptr<::Ice::Value>&" + }; + static const char* cpp11InputBuiltinTable[] = + { + "::Ice::Byte", + "bool", + "short", + "int", + "long long int", + "float", + "double", + "::std::string&", + "::std::shared_ptr<::Ice::Object>", + "::std::shared_ptr<::Ice::ObjectPrx>", + "::std::shared_ptr<void>", + "::std::shared_ptr<::Ice::Value>" + }; + + typeCtx |= TypeContextInParam; if(optional) { - return "const IceUtil::Optional<" + toTemplateArg(typeToString(type, metaData, typeCtx, cpp11)) +">&"; + if(cpp11 && !(typeCtx & TypeContextLocalOperation) && + !(typeCtx & TypeContextAMD)) + { + return "IceUtil::Optional<" + toTemplateArg(typeToString(type, metaData, typeCtx, cpp11)) +">"; + } + else + { + return "const IceUtil::Optional<" + toTemplateArg(typeToString(type, metaData, typeCtx, cpp11)) +">&"; + } } BuiltinPtr builtin = BuiltinPtr::dynamicCast(type); @@ -706,7 +731,14 @@ Slice::inputTypeToString(const TypePtr& type, bool optional, const StringList& m { if(builtin->kind() == Builtin::KindString) { - return string("const ") + stringTypeToString(type, metaData, typeCtx) + "&"; + if(cpp11 && !(typeCtx & TypeContextLocalOperation) && !(typeCtx & TypeContextAMD)) + { + return stringTypeToString(type, metaData, typeCtx); + } + else + { + return string("const ") + stringTypeToString(type, metaData, typeCtx) + "&"; + } } else { @@ -714,16 +746,30 @@ Slice::inputTypeToString(const TypePtr& type, bool optional, const StringList& m { if(builtin->kind() == Builtin::KindObject && !(typeCtx & TypeContextLocalOperation)) { - return "const ::std::shared_ptr<::Ice::Value>&"; + if(typeCtx & TypeContextAMD) + { + return "const ::std::shared_ptr<::Ice::Value>&"; + } + else + { + return "::std::shared_ptr<::Ice::Value>"; + } } else { - return cpp11InputBuiltinTable[builtin->kind()]; + if(typeCtx & TypeContextLocalOperation || typeCtx & TypeContextAMD) + { + return cpp11InputLocalBuiltinTable[builtin->kind()]; + } + else + { + return cpp11InputBuiltinTable[builtin->kind()]; + } } } else { - return inputBuiltinTable[builtin->kind()]; + return cpp98InputBuiltinTable[builtin->kind()]; } } } @@ -738,17 +784,41 @@ Slice::inputTypeToString(const TypePtr& type, bool optional, const StringList& m { return t; } - else if(cl->isInterface() && !cl->isLocal()) - { - return "const ::std::shared_ptr<::Ice::Value>&"; - } - else if(cl->definition() && cl->definition()->isDelegate()) + else if(cl->isLocal() || (typeCtx & TypeContextLocalOperation)) { - return classDefToDelegateString(cl->definition(), typeCtx, cpp11); + if(cl->definition() && cl->definition()->isDelegate()) + { + return classDefToDelegateString(cl->definition(), typeCtx, cpp11); + } + else + { + return "const ::std::shared_ptr<" + fixKwd(cl->scoped()) + ">&"; + } } else { - return "const ::std::shared_ptr<" + fixKwd(cl->scoped()) + ">&"; + if(typeCtx & TypeContextAMD) + { + if(cl->isInterface()) + { + return "const ::std::shared_ptr<::Ice::Value>&"; + } + else + { + return "const ::std::shared_ptr<" + fixKwd(cl->scoped()) + ">&"; + } + } + else + { + if(cl->isInterface()) + { + return "::std::shared_ptr<::Ice::Value>"; + } + else + { + return "::std::shared_ptr<" + fixKwd(cl->scoped()) + ">"; + } + } } } else @@ -760,11 +830,28 @@ Slice::inputTypeToString(const TypePtr& type, bool optional, const StringList& m StructPtr st = StructPtr::dynamicCast(type); if(st) { - if(!cpp11 && findMetaData(st->getMetaData()) == "%class") + if(cpp11) + { + if(st->isLocal() || (typeCtx & TypeContextLocalOperation) || (typeCtx & TypeContextAMD)) + { + return "const " + fixKwd(st->scoped()) + "&"; + } + else + { + return fixKwd(st->scoped()); + } + } + else { - return "const " + fixKwd(st->scoped() + "Ptr&"); + if(findMetaData(st->getMetaData()) == "%class") + { + return "const " + fixKwd(st->scoped() + "Ptr&"); + } + else + { + return "const " + fixKwd(st->scoped()) + "&"; + } } - return "const " + fixKwd(st->scoped()) + "&"; } ProxyPtr proxy = ProxyPtr::dynamicCast(type); @@ -777,13 +864,30 @@ Slice::inputTypeToString(const TypePtr& type, bool optional, const StringList& m // Non local classes without operations map to the base // proxy class shared_ptr<Ice::ObjectPrx> // - if(def && !def->isInterface() && def->allOperations().empty()) + if(typeCtx & TypeContextLocalOperation) { - return "const ::std::shared_ptr<::Ice::ObjectPrx>"; + if(def && !def->isInterface() && def->allOperations().empty()) + { + return "const ::std::shared_ptr<::Ice::ObjectPrx>&"; + } + else + { + return "const ::std::shared_ptr<" + fixKwd(proxy->_class()->scoped() + "Prx") + ">&"; + } } else { - return "const ::std::shared_ptr<" + fixKwd(proxy->_class()->scoped() + "Prx") + ">&"; + string t; + if(def && !def->isInterface() && def->allOperations().empty()) + { + t = "::std::shared_ptr<::Ice::ObjectPrx>"; + } + else + { + t = "::std::shared_ptr<" + fixKwd(proxy->_class()->scoped() + "Prx") + ">"; + } + + return (typeCtx & TypeContextAMD) ? ("const " + t + "&") : t; } } else @@ -801,19 +905,40 @@ Slice::inputTypeToString(const TypePtr& type, bool optional, const StringList& m SequencePtr seq = SequencePtr::dynamicCast(type); if(seq) { - return "const " + sequenceTypeToString(seq, metaData, typeCtx) + "&"; + if(cpp11 && !(typeCtx & TypeContextLocalOperation) && !(typeCtx & TypeContextAMD)) + { + return sequenceTypeToString(seq, metaData, typeCtx); + } + else + { + return "const " + sequenceTypeToString(seq, metaData, typeCtx) + "&"; + } } DictionaryPtr dict = DictionaryPtr::dynamicCast(type); if(dict) { - return "const " + dictionaryTypeToString(dict, metaData, typeCtx) + "&"; + if(cpp11 && !(typeCtx & TypeContextLocalOperation) && !(typeCtx & TypeContextAMD)) + { + return dictionaryTypeToString(dict, metaData, typeCtx); + } + else + { + return "const " + dictionaryTypeToString(dict, metaData, typeCtx) + "&"; + } } ContainedPtr contained = ContainedPtr::dynamicCast(type); if(contained) { - return "const " + fixKwd(contained->scoped()) + "&"; + if(cpp11 && !(typeCtx & TypeContextLocalOperation) && !(typeCtx & TypeContextAMD)) + { + return fixKwd(contained->scoped()); + } + else + { + return "const " + fixKwd(contained->scoped()) + "&"; + } } return "???"; diff --git a/cpp/src/slice2cpp/Gen.cpp b/cpp/src/slice2cpp/Gen.cpp index c3d994ff1f5..8e598e882a9 100644 --- a/cpp/src/slice2cpp/Gen.cpp +++ b/cpp/src/slice2cpp/Gen.cpp @@ -8105,7 +8105,7 @@ Slice::Gen::Cpp11InterfaceVisitor::visitOperation(const OperationPtr& p) paramsDecl += typeString; paramsDecl += ' '; paramsDecl += paramName; - args += paramName; + args += (isMovable(type) && !isOutParam) ? ("::std::move(" + paramName + ")") : paramName; } if(!paramList.empty()) @@ -8127,12 +8127,19 @@ Slice::Gen::Cpp11InterfaceVisitor::visitOperation(const OperationPtr& p) argsAMD += ", "; } paramsAMD += inputTypeToString((*q)->type(), (*q)->optional(), (*q)->getMetaData(), _useWstring, true); - argsAMD += fixKwd(string(paramPrefix) + (*q)->name()); + if(isMovable((*q)->type())) + { + argsAMD += "::std::move(" + fixKwd(string(paramPrefix) + (*q)->name()) + ")"; + } + else + { + argsAMD += fixKwd(string(paramPrefix) + (*q)->name()); + } } if(ret) { - string typeString = inputTypeToString(ret, p->returnIsOptional(), p->getMetaData(), _useWstring, true); + string typeString = inputTypeToString(ret, p->returnIsOptional(), p->getMetaData(), _useWstring | TypeContextAMD, true); responseParams = typeString; responseParamsDecl = typeString + " __ret"; if(!outParams.empty()) @@ -8150,7 +8157,7 @@ Slice::Gen::Cpp11InterfaceVisitor::visitOperation(const OperationPtr& p) responseParamsDecl += ", "; } string paramName = fixKwd(string(paramPrefix) + (*q)->name()); - string typeString = inputTypeToString((*q)->type(), (*q)->optional(), (*q)->getMetaData(), _useWstring, true); + string typeString = inputTypeToString((*q)->type(), (*q)->optional(), (*q)->getMetaData(), _useWstring | TypeContextAMD, true); responseParams += typeString; responseParamsDecl += typeString + " " + paramName; } @@ -8191,7 +8198,7 @@ Slice::Gen::Cpp11InterfaceVisitor::visitOperation(const OperationPtr& p) H << "," << nl; } H << "::std::function<void (" << responseParams << ")>," << nl - << "::std::function<void (const ::std::exception_ptr&)>, const Ice::Current&)" + << "::std::function<void (::std::exception_ptr)>, const Ice::Current&)" << (isConst ? " const" : "") << " = 0;"; H.restoreIndent(); } @@ -8268,7 +8275,7 @@ Slice::Gen::Cpp11InterfaceVisitor::visitOperation(const OperationPtr& p) else { C << nl << "auto inS = ::std::make_shared<::IceInternal::IncomingAsync>(__inS);"; - C << nl << "auto __exception = [inS](const ::std::exception_ptr& e)"; + C << nl << "auto __exception = [inS](::std::exception_ptr e)"; C << sb; C << nl << "try"; C << sb; diff --git a/cpp/test/Ice/admin/AllTests.cpp b/cpp/test/Ice/admin/AllTests.cpp index 43bf5d0fdfc..09131385924 100644 --- a/cpp/test/Ice/admin/AllTests.cpp +++ b/cpp/test/Ice/admin/AllTests.cpp @@ -99,8 +99,8 @@ public: RemoteLoggerI(); - virtual void init(const string&, const Ice::LogMessageSeq&, const Ice::Current&); - virtual void log(const Ice::LogMessage&, const Ice::Current&); + virtual void init(ICE_IN(string), ICE_IN(Ice::LogMessageSeq), const Ice::Current&); + virtual void log(ICE_IN(Ice::LogMessage), const Ice::Current&); void checkNextInit(const string&, const Ice::LogMessageSeq&); void checkNextLog(Ice::LogMessageType, const string&, const string& = ""); @@ -126,7 +126,7 @@ RemoteLoggerI::RemoteLoggerI() : _receivedCalls(0) } void -RemoteLoggerI::init(const string& prefix, const Ice::LogMessageSeq& logMessages, const Ice::Current&) +RemoteLoggerI::init(ICE_IN(string) prefix, ICE_IN(Ice::LogMessageSeq) logMessages, const Ice::Current&) { IceUtil::Monitor<IceUtil::Mutex>::Lock lock(_monitor); test(prefix == _expectedPrefix); @@ -136,7 +136,7 @@ RemoteLoggerI::init(const string& prefix, const Ice::LogMessageSeq& logMessages, } void -RemoteLoggerI::log(const Ice::LogMessage& logMessage, const Ice::Current&) +RemoteLoggerI::log(ICE_IN(Ice::LogMessage) logMessage, const Ice::Current&) { IceUtil::Monitor<IceUtil::Mutex>::Lock lock(_monitor); Ice::LogMessage front = _expectedLogMessages.front(); diff --git a/cpp/test/Ice/admin/TestI.cpp b/cpp/test/Ice/admin/TestI.cpp index 3cd1188aa1f..64ab0d191af 100644 --- a/cpp/test/Ice/admin/TestI.cpp +++ b/cpp/test/Ice/admin/TestI.cpp @@ -88,23 +88,23 @@ RemoteCommunicatorI::getChanges(const Ice::Current&) } void -RemoteCommunicatorI::print(const std::string& message, const Ice::Current&) +RemoteCommunicatorI::print(ICE_IN(std::string) message, const Ice::Current&) { _communicator->getLogger()->print(message); } void -RemoteCommunicatorI::trace(const std::string& category, - const std::string& message, const Ice::Current&) +RemoteCommunicatorI::trace(ICE_IN(std::string) category, + ICE_IN(std::string) message, const Ice::Current&) { _communicator->getLogger()->trace(category, message); } void -RemoteCommunicatorI::warning(const std::string& message, const Ice::Current&) +RemoteCommunicatorI::warning(ICE_IN(std::string) message, const Ice::Current&) { _communicator->getLogger()->warning(message); } void -RemoteCommunicatorI::error(const std::string& message, const Ice::Current&) +RemoteCommunicatorI::error(ICE_IN(std::string) message, const Ice::Current&) { _communicator->getLogger()->error(message); } @@ -142,7 +142,7 @@ RemoteCommunicatorI::updated(const Ice::PropertyDict& changes) } Test::RemoteCommunicatorPrxPtr -RemoteCommunicatorFactoryI::createCommunicator(const Ice::PropertyDict& props, const Ice::Current& current) +RemoteCommunicatorFactoryI::createCommunicator(ICE_IN(Ice::PropertyDict) props, const Ice::Current& current) { // // Prepare the property set using the given properties. diff --git a/cpp/test/Ice/admin/TestI.h b/cpp/test/Ice/admin/TestI.h index 6539b48153d..5a207838356 100644 --- a/cpp/test/Ice/admin/TestI.h +++ b/cpp/test/Ice/admin/TestI.h @@ -11,6 +11,7 @@ #define TEST_I_H #include <Test.h> +#include <TestCommon.h> #include <Ice/NativePropertiesAdmin.h> class RemoteCommunicatorI : virtual public Test::RemoteCommunicator, @@ -24,10 +25,10 @@ public: virtual Ice::ObjectPrxPtr getAdmin(const Ice::Current&); virtual Ice::PropertyDict getChanges(const Ice::Current&); - virtual void print(const std::string&, const Ice::Current&); - virtual void trace(const std::string&, const std::string&, const Ice::Current&); - virtual void warning(const std::string&, const Ice::Current&); - virtual void error(const std::string&, const Ice::Current&); + virtual void print(ICE_IN(std::string), const Ice::Current&); + virtual void trace(ICE_IN(std::string), ICE_IN(std::string), const Ice::Current&); + virtual void warning(ICE_IN(std::string), const Ice::Current&); + virtual void error(ICE_IN(std::string), const Ice::Current&); virtual void shutdown(const Ice::Current&); virtual void waitForShutdown(const Ice::Current&); @@ -47,7 +48,7 @@ class RemoteCommunicatorFactoryI : public Test::RemoteCommunicatorFactory { public: - virtual Test::RemoteCommunicatorPrxPtr createCommunicator(const Ice::PropertyDict&, const Ice::Current&); + virtual Test::RemoteCommunicatorPrxPtr createCommunicator(ICE_IN(Ice::PropertyDict), const Ice::Current&); virtual void shutdown(const Ice::Current&); }; diff --git a/cpp/test/Ice/ami/TestI.cpp b/cpp/test/Ice/ami/TestI.cpp index e418621289d..066dabb56d8 100644 --- a/cpp/test/Ice/ami/TestI.cpp +++ b/cpp/test/Ice/ami/TestI.cpp @@ -36,7 +36,7 @@ TestIntfI::opWithUE(const Ice::Current&) } void -TestIntfI::opWithPayload(const Ice::ByteSeq&, const Ice::Current&) +TestIntfI::opWithPayload(ICE_IN(Ice::ByteSeq), const Ice::Current&) { } diff --git a/cpp/test/Ice/ami/TestI.h b/cpp/test/Ice/ami/TestI.h index 8e9a0128ee2..c96f76b834b 100644 --- a/cpp/test/Ice/ami/TestI.h +++ b/cpp/test/Ice/ami/TestI.h @@ -11,6 +11,7 @@ #define TEST_I_H #include <Test.h> +#include <TestCommon.h> class TestIntfControllerI; ICE_DEFINE_PTR(TestIntfControllerIPtr, TestIntfControllerI); @@ -24,7 +25,7 @@ public: virtual void op(const Ice::Current&); virtual int opWithResult(const Ice::Current&); virtual void opWithUE(const Ice::Current&); - virtual void opWithPayload(const Ice::ByteSeq&, const Ice::Current&); + virtual void opWithPayload(ICE_IN(Ice::ByteSeq), const Ice::Current&); virtual void opBatch(const Ice::Current&); virtual Ice::Int opBatchCount(const Ice::Current&); virtual void opWithArgs(Ice::Int&, Ice::Int&, Ice::Int&, Ice::Int&, Ice::Int&, Ice::Int&, Ice::Int&, diff --git a/cpp/test/Ice/enums/TestI.cpp b/cpp/test/Ice/enums/TestI.cpp index f33fb635982..f0625fa2099 100644 --- a/cpp/test/Ice/enums/TestI.cpp +++ b/cpp/test/Ice/enums/TestI.cpp @@ -39,28 +39,28 @@ TestIntfI::opSimple(Test::SimpleEnum s1, Test::SimpleEnum& s2, const Ice::Curren } Test::ByteEnumSeq -TestIntfI::opByteSeq(const Test::ByteEnumSeq& bs1, Test::ByteEnumSeq& bs2, const Ice::Current&) +TestIntfI::opByteSeq(ICE_IN(Test::ByteEnumSeq) bs1, Test::ByteEnumSeq& bs2, const Ice::Current&) { bs2 = bs1; return bs1; } Test::ShortEnumSeq -TestIntfI::opShortSeq(const Test::ShortEnumSeq& ss1, Test::ShortEnumSeq& ss2, const ::Ice::Current&) +TestIntfI::opShortSeq(ICE_IN(Test::ShortEnumSeq) ss1, Test::ShortEnumSeq& ss2, const ::Ice::Current&) { ss2 = ss1; return ss1; } Test::IntEnumSeq -TestIntfI::opIntSeq(const Test::IntEnumSeq& is1, Test::IntEnumSeq& is2, const ::Ice::Current&) +TestIntfI::opIntSeq(ICE_IN(Test::IntEnumSeq) is1, Test::IntEnumSeq& is2, const ::Ice::Current&) { is2 = is1; return is1; } Test::SimpleEnumSeq -TestIntfI::opSimpleSeq(const Test::SimpleEnumSeq& ss1, Test::SimpleEnumSeq& ss2, const ::Ice::Current&) +TestIntfI::opSimpleSeq(ICE_IN(Test::SimpleEnumSeq) ss1, Test::SimpleEnumSeq& ss2, const ::Ice::Current&) { ss2 = ss1; return ss1; diff --git a/cpp/test/Ice/enums/TestI.h b/cpp/test/Ice/enums/TestI.h index 7fd5af4ec22..d0a925d6d97 100644 --- a/cpp/test/Ice/enums/TestI.h +++ b/cpp/test/Ice/enums/TestI.h @@ -11,6 +11,7 @@ #define TEST_I_H #include <Test.h> +#include <TestCommon.h> class TestIntfI : virtual public Test::TestIntf { @@ -24,13 +25,13 @@ public: virtual Test::SimpleEnum opSimple(Test::SimpleEnum, Test::SimpleEnum&, const Ice::Current&); - virtual Test::ByteEnumSeq opByteSeq(const Test::ByteEnumSeq&, Test::ByteEnumSeq&, const Ice::Current&); + virtual Test::ByteEnumSeq opByteSeq(ICE_IN(Test::ByteEnumSeq), Test::ByteEnumSeq&, const Ice::Current&); - virtual Test::ShortEnumSeq opShortSeq(const Test::ShortEnumSeq&, Test::ShortEnumSeq&, const ::Ice::Current&); + virtual Test::ShortEnumSeq opShortSeq(ICE_IN(Test::ShortEnumSeq), Test::ShortEnumSeq&, const ::Ice::Current&); - virtual Test::IntEnumSeq opIntSeq(const Test::IntEnumSeq&, Test::IntEnumSeq&, const ::Ice::Current&); + virtual Test::IntEnumSeq opIntSeq(ICE_IN(Test::IntEnumSeq), Test::IntEnumSeq&, const ::Ice::Current&); - virtual Test::SimpleEnumSeq opSimpleSeq(const Test::SimpleEnumSeq&, Test::SimpleEnumSeq&, const ::Ice::Current&); + virtual Test::SimpleEnumSeq opSimpleSeq(ICE_IN(Test::SimpleEnumSeq), Test::SimpleEnumSeq&, const ::Ice::Current&); virtual void shutdown(const Ice::Current&); }; diff --git a/cpp/test/Ice/exceptions/TestAMDI.cpp b/cpp/test/Ice/exceptions/TestAMDI.cpp index 46646fbc721..82e55dd7ecd 100644 --- a/cpp/test/Ice/exceptions/TestAMDI.cpp +++ b/cpp/test/Ice/exceptions/TestAMDI.cpp @@ -31,7 +31,7 @@ ThrowerI::ThrowerI() #ifdef ICE_CPP11_MAPPING void ThrowerI::shutdown_async(function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current& current) { current.adapter->getCommunicator()->shutdown(); @@ -40,7 +40,7 @@ ThrowerI::shutdown_async(function<void ()> response, void ThrowerI::supportsUndeclaredExceptions_async(function<void (bool)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(true); @@ -48,7 +48,7 @@ ThrowerI::supportsUndeclaredExceptions_async(function<void (bool)> response, void ThrowerI::supportsAssertException_async(function<void (bool)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(false); @@ -57,7 +57,7 @@ ThrowerI::supportsAssertException_async(function<void (bool)> response, void ThrowerI::throwAasA_async(int a, function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { try @@ -75,7 +75,7 @@ ThrowerI::throwAasA_async(int a, void ThrowerI::throwAorDasAorD_async(int a, function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { try @@ -102,7 +102,7 @@ ThrowerI::throwAorDasAorD_async(int a, void ThrowerI::throwBasA_async(int a, int b, function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { try @@ -121,7 +121,7 @@ ThrowerI::throwBasA_async(int a, int b, void ThrowerI::throwCasA_async(int a, int b, int c, function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { try @@ -141,7 +141,7 @@ ThrowerI::throwCasA_async(int a, int b, int c, void ThrowerI::throwBasB_async(int a, int b, function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { try @@ -160,7 +160,7 @@ ThrowerI::throwBasB_async(int a, int b, void ThrowerI::throwCasB_async(int a, int b, int c, function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { try @@ -180,7 +180,7 @@ ThrowerI::throwCasB_async(int a, int b, int c, void ThrowerI::throwCasC_async(int a, int b, int c, function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { try @@ -200,7 +200,7 @@ ThrowerI::throwCasC_async(int a, int b, int c, void ThrowerI::throwModA_async(int a, int a2, function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { Mod::A ex; @@ -212,7 +212,7 @@ ThrowerI::throwModA_async(int a, int a2, void ThrowerI::throwUndeclaredA_async(int a, function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { try @@ -230,7 +230,7 @@ ThrowerI::throwUndeclaredA_async(int a, void ThrowerI::throwUndeclaredB_async(int a, int b, function<void ()>, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { B ex; @@ -242,7 +242,7 @@ ThrowerI::throwUndeclaredB_async(int a, int b, void ThrowerI::throwUndeclaredC_async(int a, int b, int c, function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { try @@ -261,7 +261,7 @@ ThrowerI::throwUndeclaredC_async(int a, int b, int c, void ThrowerI::throwLocalException_async(function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { try @@ -276,7 +276,7 @@ ThrowerI::throwLocalException_async(function<void ()>, void ThrowerI::throwNonIceException_async(function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { try @@ -291,16 +291,16 @@ ThrowerI::throwNonIceException_async(function<void ()>, void ThrowerI::throwAssertException_async(function<void ()>, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { assert(false); // No supported in C++ } void -ThrowerI::throwMemoryLimitException_async(const Ice::ByteSeq&, +ThrowerI::throwMemoryLimitException_async(ICE_IN(Ice::ByteSeq), function<void (const Ice::ByteSeq&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(Ice::ByteSeq(1024 * 20)); // 20 KB. @@ -308,7 +308,7 @@ ThrowerI::throwMemoryLimitException_async(const Ice::ByteSeq&, void ThrowerI::throwLocalExceptionIdempotent_async(function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { try @@ -324,7 +324,7 @@ ThrowerI::throwLocalExceptionIdempotent_async(function<void ()>, void ThrowerI::throwAfterResponse_async(function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(); @@ -334,7 +334,7 @@ ThrowerI::throwAfterResponse_async(function<void ()> response, void ThrowerI::throwAfterException_async(function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { try @@ -350,7 +350,7 @@ ThrowerI::throwAfterException_async(function<void ()>, void ThrowerI::throwE_async(function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { try @@ -365,7 +365,7 @@ ThrowerI::throwE_async(function<void ()>, void ThrowerI::throwF_async(function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { try @@ -380,7 +380,7 @@ ThrowerI::throwF_async(function<void ()>, void ThrowerI::throwG_async(function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { try @@ -399,7 +399,7 @@ ThrowerI::throwG_async(function<void ()>, void ThrowerI::throwH_async(function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const Ice::Current&) { try diff --git a/cpp/test/Ice/exceptions/TestAMDI.h b/cpp/test/Ice/exceptions/TestAMDI.h index bbc244e6d5a..df096caf3c6 100644 --- a/cpp/test/Ice/exceptions/TestAMDI.h +++ b/cpp/test/Ice/exceptions/TestAMDI.h @@ -11,6 +11,7 @@ #define TEST_I_H #include <TestAMD.h> +#include <TestCommon.h> bool endsWith(const std::string&, const std::string&); @@ -23,115 +24,115 @@ public: #ifdef ICE_CPP11_MAPPING virtual void shutdown_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void supportsUndeclaredExceptions_async(std::function<void (bool)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void supportsAssertException_async(std::function<void (bool)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwAasA_async(int, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwAorDasAorD_async(int, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwBasA_async(int, int, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwCasA_async(int, int, int, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwBasB_async(int, int, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwCasB_async(int, int, int, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwCasC_async(int, int, int, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwModA_async(int, int, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwUndeclaredA_async(int, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwUndeclaredB_async(int, int, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwUndeclaredC_async(int, int, int, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwLocalException_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwNonIceException_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwAssertException_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void throwMemoryLimitException_async(const Ice::ByteSeq&, + virtual void throwMemoryLimitException_async(ICE_IN(Ice::ByteSeq), std::function<void (const Ice::ByteSeq&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwLocalExceptionIdempotent_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwAfterResponse_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwAfterException_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwE_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwF_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwG_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void throwH_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); #else virtual void shutdown_async(const Test::AMD_Thrower_shutdownPtr&, diff --git a/cpp/test/Ice/exceptions/TestI.cpp b/cpp/test/Ice/exceptions/TestI.cpp index 7d538775fdf..3f1c332cfba 100644 --- a/cpp/test/Ice/exceptions/TestI.cpp +++ b/cpp/test/Ice/exceptions/TestI.cpp @@ -153,7 +153,7 @@ ThrowerI::throwAssertException(const Ice::Current&) } Ice::ByteSeq -ThrowerI::throwMemoryLimitException(const Ice::ByteSeq&, const Ice::Current&) +ThrowerI::throwMemoryLimitException(ICE_IN(Ice::ByteSeq), const Ice::Current&) { return Ice::ByteSeq(1024 * 20); // 20 KB. } diff --git a/cpp/test/Ice/exceptions/TestI.h b/cpp/test/Ice/exceptions/TestI.h index 64b38b63ece..653a9914b15 100644 --- a/cpp/test/Ice/exceptions/TestI.h +++ b/cpp/test/Ice/exceptions/TestI.h @@ -11,6 +11,7 @@ #define TEST_I_H #include <Test.h> +#include <TestCommon.h> bool endsWith(const std::string&, const std::string&); @@ -40,7 +41,7 @@ public: virtual void throwLocalException(const Ice::Current&); virtual void throwNonIceException(const Ice::Current&); virtual void throwAssertException(const Ice::Current&); - virtual Ice::ByteSeq throwMemoryLimitException(const Ice::ByteSeq&, const Ice::Current&); + virtual Ice::ByteSeq throwMemoryLimitException(ICE_IN(Ice::ByteSeq), const Ice::Current&); virtual void throwLocalExceptionIdempotent(const Ice::Current&); diff --git a/cpp/test/Ice/inheritance/TestI.cpp b/cpp/test/Ice/inheritance/TestI.cpp index 59da259eb00..378b52a766e 100644 --- a/cpp/test/Ice/inheritance/TestI.cpp +++ b/cpp/test/Ice/inheritance/TestI.cpp @@ -13,49 +13,49 @@ using namespace Test; MA::CAPrxPtr -CAI_::caop(const MA::CAPrxPtr& p, const Ice::Current&) +CAI_::caop(ICE_IN(MA::CAPrxPtr) p, const Ice::Current&) { return p; } MB::CBPrxPtr -CBI::cbop(const MB::CBPrxPtr& p, const Ice::Current&) +CBI::cbop(ICE_IN(MB::CBPrxPtr) p, const Ice::Current&) { return p; } MA::CCPrxPtr -CCI::ccop(const MA::CCPrxPtr& p, const Ice::Current&) +CCI::ccop(ICE_IN(MA::CCPrxPtr) p, const Ice::Current&) { return p; } MA::CDPrxPtr -CDI::cdop(const MA::CDPrxPtr& p, const Ice::Current&) +CDI::cdop(ICE_IN(MA::CDPrxPtr) p, const Ice::Current&) { return p; } MA::IAPrxPtr -IAI::iaop(const MA::IAPrxPtr& p, const Ice::Current&) +IAI::iaop(ICE_IN(MA::IAPrxPtr) p, const Ice::Current&) { return p; } MB::IB1PrxPtr -IB1I::ib1op(const MB::IB1PrxPtr& p, const Ice::Current&) +IB1I::ib1op(ICE_IN(MB::IB1PrxPtr) p, const Ice::Current&) { return p; } MB::IB2PrxPtr -IB2I::ib2op(const MB::IB2PrxPtr& p, const Ice::Current&) +IB2I::ib2op(ICE_IN(MB::IB2PrxPtr) p, const Ice::Current&) { return p; } MA::ICPrxPtr -ICI::icop(const MA::ICPrxPtr& p, const Ice::Current&) +ICI::icop(ICE_IN(MA::ICPrxPtr) p, const Ice::Current&) { return p; } diff --git a/cpp/test/Ice/inheritance/TestI.h b/cpp/test/Ice/inheritance/TestI.h index bdb11e987da..aba8de29de6 100644 --- a/cpp/test/Ice/inheritance/TestI.h +++ b/cpp/test/Ice/inheritance/TestI.h @@ -11,6 +11,7 @@ #define TESTI_H #include <Test.h> +#include <TestCommon.h> class InitialI : public Test::Initial { @@ -46,28 +47,28 @@ class CAI_ : virtual public Test::MA::CADisp { public: - virtual std::shared_ptr<Test::MA::CAPrx> caop(const std::shared_ptr<Test::MA::CAPrx>&, const Ice::Current&); + virtual std::shared_ptr<Test::MA::CAPrx> caop(std::shared_ptr<Test::MA::CAPrx>, const Ice::Current&); }; class CBI : virtual public Test::MB::CBDisp, virtual public CAI_ { public: - virtual std::shared_ptr<Test::MB::CBPrx> cbop(const std::shared_ptr<Test::MB::CBPrx>&, const Ice::Current&); + virtual std::shared_ptr<Test::MB::CBPrx> cbop(std::shared_ptr<Test::MB::CBPrx>, const Ice::Current&); }; class CCI : virtual public Test::MA::CCDisp, virtual public CBI { public: - virtual std::shared_ptr<Test::MA::CCPrx> ccop(const std::shared_ptr<Test::MA::CCPrx>&, const Ice::Current&); + virtual std::shared_ptr<Test::MA::CCPrx> ccop(std::shared_ptr<Test::MA::CCPrx>, const Ice::Current&); }; class IAI : virtual public Test::MA::IA { public: - virtual std::shared_ptr<Test::MA::IAPrx> iaop(const std::shared_ptr<Test::MA::IAPrx>&, const Ice::Current&); + virtual std::shared_ptr<Test::MA::IAPrx> iaop(std::shared_ptr<Test::MA::IAPrx>, const Ice::Current&); }; class IB1I : virtual public Test::MB::IB1, @@ -75,28 +76,28 @@ class IB1I : virtual public Test::MB::IB1, { public: - virtual std::shared_ptr<Test::MB::IB1Prx> ib1op(const std::shared_ptr<Test::MB::IB1Prx>&, const Ice::Current&); + virtual std::shared_ptr<Test::MB::IB1Prx> ib1op(std::shared_ptr<Test::MB::IB1Prx>, const Ice::Current&); }; class IB2I : virtual public Test::MB::IB2, virtual public IAI { public: - virtual std::shared_ptr<Test::MB::IB2Prx> ib2op(const std::shared_ptr<Test::MB::IB2Prx>&, const Ice::Current&); + virtual std::shared_ptr<Test::MB::IB2Prx> ib2op(std::shared_ptr<Test::MB::IB2Prx>, const Ice::Current&); }; class ICI : virtual public Test::MA::IC, virtual public IB1I, virtual public IB2I { public: - virtual std::shared_ptr<Test::MA::ICPrx> icop(const std::shared_ptr<Test::MA::ICPrx>&, const Ice::Current&); + virtual std::shared_ptr<Test::MA::ICPrx> icop(std::shared_ptr<Test::MA::ICPrx>, const Ice::Current&); }; class CDI : virtual public Test::MA::CDDisp, virtual public CCI, virtual public IB1I, virtual public IB2I { public: - virtual std::shared_ptr<Test::MA::CDPrx> cdop(const std::shared_ptr<Test::MA::CDPrx>&, const Ice::Current&); + virtual std::shared_ptr<Test::MA::CDPrx> cdop(std::shared_ptr<Test::MA::CDPrx>, const Ice::Current&); }; #else class CAI_ : virtual public Test::MA::CA diff --git a/cpp/test/Ice/objects/TestI.cpp b/cpp/test/Ice/objects/TestI.cpp index 42d6ab7c553..72e53efb9fa 100644 --- a/cpp/test/Ice/objects/TestI.cpp +++ b/cpp/test/Ice/objects/TestI.cpp @@ -215,7 +215,7 @@ InitialI::getI(const Ice::Current&) } void -InitialI::setI(const shared_ptr<Ice::Value>&, const Ice::Current&) +InitialI::setI(ICE_IN(shared_ptr<Ice::Value>), const Ice::Current&) { } #else @@ -232,7 +232,7 @@ InitialI::setI(const IPtr&, const Ice::Current&) #endif BaseSeq -InitialI::opBaseSeq(const BaseSeq& inSeq, BaseSeq& outSeq, const Ice::Current&) +InitialI::opBaseSeq(ICE_IN(BaseSeq) inSeq, BaseSeq& outSeq, const Ice::Current&) { outSeq = inSeq; return inSeq; @@ -299,7 +299,7 @@ InitialI::getH(const Ice::Current&) #endif D1Ptr -InitialI::getD1(const Test::D1Ptr& d1, const Ice::Current&) +InitialI::getD1(ICE_IN(Test::D1Ptr) d1, const Ice::Current&) { return d1; } diff --git a/cpp/test/Ice/objects/TestI.h b/cpp/test/Ice/objects/TestI.h index ffe39565048..97e655c8e88 100644 --- a/cpp/test/Ice/objects/TestI.h +++ b/cpp/test/Ice/objects/TestI.h @@ -11,6 +11,7 @@ #define TEST_I_H #include <Test.h> +#include <TestCommon.h> class BI : public Test::B { @@ -131,15 +132,15 @@ public: virtual Test::IPtr getH(const Ice::Current&); #endif - virtual Test::D1Ptr getD1(const Test::D1Ptr&, const Ice::Current&); + virtual Test::D1Ptr getD1(ICE_IN(Test::D1Ptr), const Ice::Current&); virtual void throwEDerived(const Ice::Current&); #ifdef ICE_CPP11_MAPPING - virtual void setI(const ::std::shared_ptr<::Ice::Value>&, const Ice::Current&); + virtual void setI(::std::shared_ptr<::Ice::Value>, const Ice::Current&); #else virtual void setI(const Test::IPtr&, const Ice::Current&); #endif - virtual Test::BaseSeq opBaseSeq(const Test::BaseSeq&, Test::BaseSeq&, const Ice::Current&); + virtual Test::BaseSeq opBaseSeq(ICE_IN(Test::BaseSeq), Test::BaseSeq&, const Ice::Current&); virtual Test::CompactPtr getCompact(const Ice::Current&); diff --git a/cpp/test/Ice/operations/TestAMDI.cpp b/cpp/test/Ice/operations/TestAMDI.cpp index 770e9570e04..7a9f9c2e9dc 100644 --- a/cpp/test/Ice/operations/TestAMDI.cpp +++ b/cpp/test/Ice/operations/TestAMDI.cpp @@ -23,11 +23,11 @@ MyDerivedClassI::MyDerivedClassI() : _opByteSOnewayCallCount(0) } bool -MyDerivedClassI::ice_isA(const std::string& id, const Ice::Current& current) const +MyDerivedClassI::ice_isA(ICE_IN(string) id, const Ice::Current& current) const { test(current.mode == ICE_ENUM(OperationMode, Nonmutating)); #ifdef ICE_CPP11_MAPPING - return Test::MyDerivedClassDisp::ice_isA(id, current); + return Test::MyDerivedClassDisp::ice_isA(move(id), current); #else return Test::MyDerivedClass::ice_isA(id, current); #endif @@ -89,7 +89,7 @@ private: void MyDerivedClassI::shutdown_async(function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current& current) { { @@ -107,7 +107,7 @@ MyDerivedClassI::shutdown_async(function<void ()> response, void MyDerivedClassI::delay_async(Ice::Int ms, function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { IceUtil::ThreadControl::sleep(IceUtil::Time::milliSeconds(ms)); @@ -116,7 +116,7 @@ MyDerivedClassI::delay_async(Ice::Int ms, function<void ()> response, void MyDerivedClassI::opVoid_async(function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current& current) { test(current.mode == OperationMode::Normal); @@ -137,7 +137,7 @@ void MyDerivedClassI::opByte_async(Ice::Byte p1, Ice::Byte p2, function<void (Ice::Byte, Ice::Byte)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(p1, p1 ^ p2); @@ -147,7 +147,7 @@ void MyDerivedClassI::opBool_async(bool p1, bool p2, function<void (bool, bool)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(p2, p1); @@ -159,7 +159,7 @@ MyDerivedClassI::opShortIntLong_async(short p1, int p2, long long int p3, function<void (long long int, short, int, long long int)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(p3, p1, p2, p3); @@ -170,17 +170,17 @@ void MyDerivedClassI::opFloatDouble_async(float p1, double p2, function<void (double, float, double)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(p2, p1, p2); } void -MyDerivedClassI::opString_async(const string& p1, - const string& p2, +MyDerivedClassI::opString_async(string p1, + string p2, function<void (const string&, const string&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(p1 + " " + p2, p2 + " " + p1); @@ -190,18 +190,18 @@ MyDerivedClassI::opString_async(const string& p1, void MyDerivedClassI::opMyEnum_async(Test::MyEnum p1, function<void (Test::MyEnum, Test::MyEnum)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(MyEnum::enum3, p1); } void -MyDerivedClassI::opMyClass_async(const shared_ptr<Test::MyClassPrx>& p1, +MyDerivedClassI::opMyClass_async(shared_ptr<Test::MyClassPrx> p1, function<void (const shared_ptr<Test::MyClassPrx>&, const shared_ptr<Test::MyClassPrx>&, const shared_ptr<Test::MyClassPrx>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current& current) { auto p2 = p1; @@ -211,10 +211,10 @@ MyDerivedClassI::opMyClass_async(const shared_ptr<Test::MyClassPrx>& p1, } void -MyDerivedClassI::opStruct_async(const Test::Structure& p1, - const Test::Structure& p2, +MyDerivedClassI::opStruct_async(Test::Structure p1, + Test::Structure p2, function<void (const Test::Structure&, const Test::Structure&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::Structure p3 = p1; @@ -223,10 +223,10 @@ MyDerivedClassI::opStruct_async(const Test::Structure& p1, } void -MyDerivedClassI::opByteS_async(const Test::ByteS& p1, - const Test::ByteS& p2, +MyDerivedClassI::opByteS_async(Test::ByteS p1, + Test::ByteS p2, function<void (const Test::ByteS&, const Test::ByteS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::ByteS p3; @@ -238,10 +238,10 @@ MyDerivedClassI::opByteS_async(const Test::ByteS& p1, } void -MyDerivedClassI::opBoolS_async(const Test::BoolS& p1, - const Test::BoolS& p2, +MyDerivedClassI::opBoolS_async(Test::BoolS p1, + Test::BoolS p2, function<void (const Test::BoolS&, const Test::BoolS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::BoolS p3 = p1; @@ -253,14 +253,14 @@ MyDerivedClassI::opBoolS_async(const Test::BoolS& p1, } void -MyDerivedClassI::opShortIntLongS_async(const Test::ShortS& p1, - const Test::IntS& p2, - const Test::LongS& p3, +MyDerivedClassI::opShortIntLongS_async(Test::ShortS p1, + Test::IntS p2, + Test::LongS p3, function<void (const Test::LongS&, const Test::ShortS&, const Test::IntS&, const Test::LongS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::ShortS p4 = p1; @@ -273,12 +273,12 @@ MyDerivedClassI::opShortIntLongS_async(const Test::ShortS& p1, } void -MyDerivedClassI::opFloatDoubleS_async(const Test::FloatS& p1, - const Test::DoubleS& p2, +MyDerivedClassI::opFloatDoubleS_async(Test::FloatS p1, + Test::DoubleS p2, function<void (const Test::DoubleS&, const Test::FloatS&, const Test::DoubleS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::FloatS p3 = p1; @@ -291,10 +291,10 @@ MyDerivedClassI::opFloatDoubleS_async(const Test::FloatS& p1, } void -MyDerivedClassI::opStringS_async(const Test::StringS& p1, - const Test::StringS& p2, +MyDerivedClassI::opStringS_async(Test::StringS p1, + Test::StringS p2, function<void (const Test::StringS&, const Test::StringS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::StringS p3 = p1; @@ -306,10 +306,10 @@ MyDerivedClassI::opStringS_async(const Test::StringS& p1, } void -MyDerivedClassI::opByteSS_async(const Test::ByteSS& p1, - const Test::ByteSS& p2, +MyDerivedClassI::opByteSS_async(Test::ByteSS p1, + Test::ByteSS p2, function<void (const Test::ByteSS&, const Test::ByteSS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::ByteSS p3; @@ -321,10 +321,10 @@ MyDerivedClassI::opByteSS_async(const Test::ByteSS& p1, } void -MyDerivedClassI::opBoolSS_async(const Test::BoolSS& p1, - const Test::BoolSS& p2, +MyDerivedClassI::opBoolSS_async(Test::BoolSS p1, + Test::BoolSS p2, function<void (const Test::BoolSS&, const Test::BoolSS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { auto p3 = p1; @@ -336,14 +336,14 @@ MyDerivedClassI::opBoolSS_async(const Test::BoolSS& p1, } void -MyDerivedClassI::opShortIntLongSS_async(const Test::ShortSS& p1, - const Test::IntSS& p2, - const Test::LongSS& p3, +MyDerivedClassI::opShortIntLongSS_async(Test::ShortSS p1, + Test::IntSS p2, + Test::LongSS p3, function<void (const Test::LongSS&, const Test::ShortSS&, const Test::IntSS&, const Test::LongSS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { auto p4 = p1; @@ -356,12 +356,12 @@ MyDerivedClassI::opShortIntLongSS_async(const Test::ShortSS& p1, } void -MyDerivedClassI::opFloatDoubleSS_async(const Test::FloatSS& p1, - const Test::DoubleSS& p2, +MyDerivedClassI::opFloatDoubleSS_async(Test::FloatSS p1, + Test::DoubleSS p2, function<void (const Test::DoubleSS&, const Test::FloatSS&, const Test::DoubleSS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::FloatSS p3 = p1; @@ -374,10 +374,10 @@ MyDerivedClassI::opFloatDoubleSS_async(const Test::FloatSS& p1, } void -MyDerivedClassI::opStringSS_async(const Test::StringSS& p1, - const Test::StringSS& p2, +MyDerivedClassI::opStringSS_async(Test::StringSS p1, + Test::StringSS p2, function<void (const Test::StringSS&, const Test::StringSS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::StringSS p3 = p1; @@ -389,9 +389,9 @@ MyDerivedClassI::opStringSS_async(const Test::StringSS& p1, } void -MyDerivedClassI::opStringSSS_async(const Test::StringSSS& p1, const Test::StringSSS& p2, +MyDerivedClassI::opStringSSS_async(Test::StringSSS p1, Test::StringSSS p2, function<void (const Test::StringSSS&, const Test::StringSSS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::StringSSS p3 = p1; @@ -403,9 +403,9 @@ MyDerivedClassI::opStringSSS_async(const Test::StringSSS& p1, const Test::String } void -MyDerivedClassI::opByteBoolD_async(const Test::ByteBoolD& p1, const Test::ByteBoolD& p2, +MyDerivedClassI::opByteBoolD_async(Test::ByteBoolD p1, Test::ByteBoolD p2, function<void (const Test::ByteBoolD&, const Test::ByteBoolD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::ByteBoolD p3 = p1; @@ -415,9 +415,9 @@ MyDerivedClassI::opByteBoolD_async(const Test::ByteBoolD& p1, const Test::ByteBo } void -MyDerivedClassI::opShortIntD_async(const Test::ShortIntD& p1, const Test::ShortIntD& p2, +MyDerivedClassI::opShortIntD_async(Test::ShortIntD p1, Test::ShortIntD p2, function<void (const Test::ShortIntD&, const Test::ShortIntD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::ShortIntD p3 = p1; @@ -427,9 +427,9 @@ MyDerivedClassI::opShortIntD_async(const Test::ShortIntD& p1, const Test::ShortI } void -MyDerivedClassI::opLongFloatD_async(const Test::LongFloatD& p1, const Test::LongFloatD& p2, +MyDerivedClassI::opLongFloatD_async(Test::LongFloatD p1, Test::LongFloatD p2, function<void (const Test::LongFloatD&, const Test::LongFloatD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::LongFloatD p3 = p1; @@ -439,9 +439,9 @@ MyDerivedClassI::opLongFloatD_async(const Test::LongFloatD& p1, const Test::Long } void -MyDerivedClassI::opStringStringD_async(const Test::StringStringD& p1, const Test::StringStringD& p2, +MyDerivedClassI::opStringStringD_async(Test::StringStringD p1, Test::StringStringD p2, function<void (const Test::StringStringD&, const Test::StringStringD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::StringStringD p3 = p1; @@ -451,9 +451,9 @@ MyDerivedClassI::opStringStringD_async(const Test::StringStringD& p1, const Test } void -MyDerivedClassI::opStringMyEnumD_async(const Test::StringMyEnumD& p1, const Test::StringMyEnumD& p2, +MyDerivedClassI::opStringMyEnumD_async(Test::StringMyEnumD p1, Test::StringMyEnumD p2, function<void (const Test::StringMyEnumD&, const Test::StringMyEnumD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::StringMyEnumD p3 = p1; @@ -463,9 +463,9 @@ MyDerivedClassI::opStringMyEnumD_async(const Test::StringMyEnumD& p1, const Test } void -MyDerivedClassI::opMyEnumStringD_async(const Test::MyEnumStringD& p1, const Test::MyEnumStringD& p2, +MyDerivedClassI::opMyEnumStringD_async(Test::MyEnumStringD p1, Test::MyEnumStringD p2, function<void (const Test::MyEnumStringD&, const Test::MyEnumStringD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::MyEnumStringD p3 = p1; @@ -475,10 +475,10 @@ MyDerivedClassI::opMyEnumStringD_async(const Test::MyEnumStringD& p1, const Test } void -MyDerivedClassI::opMyStructMyEnumD_async(const Test::MyStructMyEnumD& p1, const Test::MyStructMyEnumD& p2, +MyDerivedClassI::opMyStructMyEnumD_async(Test::MyStructMyEnumD p1, Test::MyStructMyEnumD p2, function<void (const Test::MyStructMyEnumD&, const Test::MyStructMyEnumD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::MyStructMyEnumD p3 = p1; @@ -488,10 +488,10 @@ MyDerivedClassI::opMyStructMyEnumD_async(const Test::MyStructMyEnumD& p1, const } void -MyDerivedClassI::opByteBoolDS_async(const Test::ByteBoolDS& p1, - const Test::ByteBoolDS& p2, +MyDerivedClassI::opByteBoolDS_async(Test::ByteBoolDS p1, + Test::ByteBoolDS p2, function<void (const Test::ByteBoolDS&, const Test::ByteBoolDS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::ByteBoolDS p3 = p2; @@ -503,9 +503,10 @@ MyDerivedClassI::opByteBoolDS_async(const Test::ByteBoolDS& p1, } void -MyDerivedClassI::opShortIntDS_async(const Test::ShortIntDS& p1, const Test::ShortIntDS& p2, +MyDerivedClassI::opShortIntDS_async(Test::ShortIntDS p1, + Test::ShortIntDS p2, function<void (const Test::ShortIntDS&, const Test::ShortIntDS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::ShortIntDS p3 = p2; @@ -517,10 +518,10 @@ MyDerivedClassI::opShortIntDS_async(const Test::ShortIntDS& p1, const Test::Shor } void -MyDerivedClassI::opLongFloatDS_async(const Test::LongFloatDS& p1, - const Test::LongFloatDS& p2, +MyDerivedClassI::opLongFloatDS_async(Test::LongFloatDS p1, + Test::LongFloatDS p2, function<void (const Test::LongFloatDS&, const Test::LongFloatDS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::LongFloatDS p3 = p2; @@ -532,10 +533,10 @@ MyDerivedClassI::opLongFloatDS_async(const Test::LongFloatDS& p1, } void -MyDerivedClassI::opStringStringDS_async(const Test::StringStringDS& p1, - const Test::StringStringDS& p2, +MyDerivedClassI::opStringStringDS_async(Test::StringStringDS p1, + Test::StringStringDS p2, function<void (const Test::StringStringDS&, const Test::StringStringDS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::StringStringDS p3 = p2; @@ -547,10 +548,10 @@ MyDerivedClassI::opStringStringDS_async(const Test::StringStringDS& p1, } void -MyDerivedClassI::opStringMyEnumDS_async(const Test::StringMyEnumDS& p1, - const Test::StringMyEnumDS& p2, +MyDerivedClassI::opStringMyEnumDS_async(Test::StringMyEnumDS p1, + Test::StringMyEnumDS p2, function<void (const Test::StringMyEnumDS&, const Test::StringMyEnumDS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::StringMyEnumDS p3 = p2; @@ -562,10 +563,10 @@ MyDerivedClassI::opStringMyEnumDS_async(const Test::StringMyEnumDS& p1, } void -MyDerivedClassI::opMyEnumStringDS_async(const Test::MyEnumStringDS& p1, - const Test::MyEnumStringDS& p2, +MyDerivedClassI::opMyEnumStringDS_async(Test::MyEnumStringDS p1, + Test::MyEnumStringDS p2, function<void (const Test::MyEnumStringDS&, const Test::MyEnumStringDS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::MyEnumStringDS p3 = p2; @@ -577,10 +578,11 @@ MyDerivedClassI::opMyEnumStringDS_async(const Test::MyEnumStringDS& p1, } void -MyDerivedClassI::opMyStructMyEnumDS_async(const Test::MyStructMyEnumDS& p1, const Test::MyStructMyEnumDS& p2, +MyDerivedClassI::opMyStructMyEnumDS_async(Test::MyStructMyEnumDS p1, + Test::MyStructMyEnumDS p2, function<void (const Test::MyStructMyEnumDS&, const Test::MyStructMyEnumDS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::MyStructMyEnumDS p3 = p2; @@ -592,9 +594,10 @@ MyDerivedClassI::opMyStructMyEnumDS_async(const Test::MyStructMyEnumDS& p1, cons } void -MyDerivedClassI::opByteByteSD_async(const Test::ByteByteSD& p1, const Test::ByteByteSD& p2, +MyDerivedClassI::opByteByteSD_async(Test::ByteByteSD p1, + Test::ByteByteSD p2, function<void (const Test::ByteByteSD&, const Test::ByteByteSD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::ByteByteSD p3 = p2; @@ -604,10 +607,10 @@ MyDerivedClassI::opByteByteSD_async(const Test::ByteByteSD& p1, const Test::Byte } void -MyDerivedClassI::opBoolBoolSD_async(const Test::BoolBoolSD& p1, - const Test::BoolBoolSD& p2, +MyDerivedClassI::opBoolBoolSD_async(Test::BoolBoolSD p1, + Test::BoolBoolSD p2, function<void (const Test::BoolBoolSD&, const Test::BoolBoolSD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::BoolBoolSD p3 = p2; @@ -617,10 +620,10 @@ MyDerivedClassI::opBoolBoolSD_async(const Test::BoolBoolSD& p1, } void -MyDerivedClassI::opShortShortSD_async(const Test::ShortShortSD& p1, - const Test::ShortShortSD& p2, +MyDerivedClassI::opShortShortSD_async(Test::ShortShortSD p1, + Test::ShortShortSD p2, function<void (const Test::ShortShortSD&, const Test::ShortShortSD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::ShortShortSD p3 = p2; @@ -630,10 +633,10 @@ MyDerivedClassI::opShortShortSD_async(const Test::ShortShortSD& p1, } void -MyDerivedClassI::opIntIntSD_async(const Test::IntIntSD& p1, - const Test::IntIntSD& p2, +MyDerivedClassI::opIntIntSD_async(Test::IntIntSD p1, + Test::IntIntSD p2, function<void (const Test::IntIntSD&, const Test::IntIntSD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::IntIntSD p3 = p2; @@ -643,10 +646,10 @@ MyDerivedClassI::opIntIntSD_async(const Test::IntIntSD& p1, } void -MyDerivedClassI::opLongLongSD_async(const Test::LongLongSD& p1, - const Test::LongLongSD& p2, +MyDerivedClassI::opLongLongSD_async(Test::LongLongSD p1, + Test::LongLongSD p2, function<void (const Test::LongLongSD&, const Test::LongLongSD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::LongLongSD p3 = p2; @@ -656,10 +659,10 @@ MyDerivedClassI::opLongLongSD_async(const Test::LongLongSD& p1, } void -MyDerivedClassI::opStringFloatSD_async(const Test::StringFloatSD& p1, - const Test::StringFloatSD& p2, +MyDerivedClassI::opStringFloatSD_async(Test::StringFloatSD p1, + Test::StringFloatSD p2, function<void (const Test::StringFloatSD&, const Test::StringFloatSD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::StringFloatSD p3 = p2; @@ -669,11 +672,11 @@ MyDerivedClassI::opStringFloatSD_async(const Test::StringFloatSD& p1, } void -MyDerivedClassI::opStringDoubleSD_async(const Test::StringDoubleSD& p1, - const Test::StringDoubleSD& p2, +MyDerivedClassI::opStringDoubleSD_async(Test::StringDoubleSD p1, + Test::StringDoubleSD p2, function<void (const Test::StringDoubleSD&, const Test::StringDoubleSD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::StringDoubleSD p3 = p2; @@ -683,10 +686,11 @@ MyDerivedClassI::opStringDoubleSD_async(const Test::StringDoubleSD& p1, } void -MyDerivedClassI::opStringStringSD_async(const Test::StringStringSD& p1, const Test::StringStringSD& p2, +MyDerivedClassI::opStringStringSD_async(Test::StringStringSD p1, + Test::StringStringSD p2, function<void (const Test::StringStringSD&, const Test::StringStringSD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::StringStringSD p3 = p2; @@ -696,10 +700,11 @@ MyDerivedClassI::opStringStringSD_async(const Test::StringStringSD& p1, const Te } void -MyDerivedClassI::opMyEnumMyEnumSD_async(const Test::MyEnumMyEnumSD& p1, const Test::MyEnumMyEnumSD& p2, +MyDerivedClassI::opMyEnumMyEnumSD_async(Test::MyEnumMyEnumSD p1, + Test::MyEnumMyEnumSD p2, function<void (const Test::MyEnumMyEnumSD&, const Test::MyEnumMyEnumSD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::MyEnumMyEnumSD p3 = p2; @@ -709,9 +714,9 @@ MyDerivedClassI::opMyEnumMyEnumSD_async(const Test::MyEnumMyEnumSD& p1, const Te } void -MyDerivedClassI::opIntS_async(const Test::IntS& s, +MyDerivedClassI::opIntS_async(Test::IntS s, function<void (const Test::IntS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Test::IntS r; @@ -720,7 +725,9 @@ MyDerivedClassI::opIntS_async(const Test::IntS& s, } void -MyDerivedClassI::opByteSOneway_async(const Test::ByteS&, function<void ()> response, function<void (const exception_ptr&)>, +MyDerivedClassI::opByteSOneway_async(Test::ByteS, + function<void ()> response, + function<void (exception_ptr)>, const Ice::Current&) { IceUtil::Mutex::Lock sync(_mutex); @@ -729,7 +736,8 @@ MyDerivedClassI::opByteSOneway_async(const Test::ByteS&, function<void ()> respo } void -MyDerivedClassI::opByteSOnewayCallCount_async(function<void (int)> response, function<void (const exception_ptr&)>, +MyDerivedClassI::opByteSOnewayCallCount_async(function<void (int)> response, + function<void (exception_ptr)>, const Ice::Current&) { IceUtil::Mutex::Lock sync(_mutex); @@ -739,7 +747,7 @@ MyDerivedClassI::opByteSOnewayCallCount_async(function<void (int)> response, fun void MyDerivedClassI::opContext_async(function<void (const Ice::Context&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current& current) { Test::StringStringD r = current.ctx; @@ -748,9 +756,9 @@ MyDerivedClassI::opContext_async(function<void (const Ice::Context&)> response, void MyDerivedClassI::opDoubleMarshaling_async(Ice::Double p1, - const Test::DoubleS& p2, + Test::DoubleS p2, function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { Ice::Double d = 1278312346.0 / 13.0; @@ -764,7 +772,7 @@ MyDerivedClassI::opDoubleMarshaling_async(Ice::Double p1, void MyDerivedClassI::opIdempotent_async(function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current& current) { test(current.mode == OperationMode::Idempotent); @@ -773,7 +781,7 @@ MyDerivedClassI::opIdempotent_async(function<void ()> response, void MyDerivedClassI::opNonmutating_async(function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current& current) { test(current.mode == OperationMode::Nonmutating); @@ -782,7 +790,7 @@ MyDerivedClassI::opNonmutating_async(function<void ()> response, void MyDerivedClassI::opDerived_async(function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(); @@ -791,7 +799,7 @@ MyDerivedClassI::opDerived_async(function<void ()> response, void MyDerivedClassI::opByte1_async(Ice::Byte b, function<void (Ice::Byte)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(b); @@ -800,7 +808,7 @@ MyDerivedClassI::opByte1_async(Ice::Byte b, void MyDerivedClassI::opShort1_async(Ice::Short s, function<void (Ice::Short)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(s); @@ -809,7 +817,7 @@ MyDerivedClassI::opShort1_async(Ice::Short s, void MyDerivedClassI::opInt1_async(Ice::Int i, function<void (Ice::Int)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(i); @@ -818,7 +826,7 @@ MyDerivedClassI::opInt1_async(Ice::Int i, void MyDerivedClassI::opLong1_async(Ice::Long l, function<void (Ice::Long)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(l); @@ -827,7 +835,7 @@ MyDerivedClassI::opLong1_async(Ice::Long l, void MyDerivedClassI::opFloat1_async(Ice::Float f, function<void (Ice::Float)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(f); @@ -836,70 +844,70 @@ MyDerivedClassI::opFloat1_async(Ice::Float f, void MyDerivedClassI::opDouble1_async(Ice::Double d, function<void (Ice::Double)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(d); } void -MyDerivedClassI::opString1_async(const string& s, +MyDerivedClassI::opString1_async(string s, function<void (const string&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(s); } void -MyDerivedClassI::opStringS1_async(const Test::StringS& seq, +MyDerivedClassI::opStringS1_async(Test::StringS seq, function<void (const Test::StringS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(seq); } void -MyDerivedClassI::opByteBoolD1_async(const Test::ByteBoolD& dict, +MyDerivedClassI::opByteBoolD1_async(Test::ByteBoolD dict, function<void (const Test::ByteBoolD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(dict); } void -MyDerivedClassI::opStringS2_async(const Test::StringS& seq, +MyDerivedClassI::opStringS2_async(Test::StringS seq, function<void (const Test::StringS&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(seq); } void -MyDerivedClassI::opByteBoolD2_async(const Test::ByteBoolD& dict, +MyDerivedClassI::opByteBoolD2_async(Test::ByteBoolD dict, function<void (const Test::ByteBoolD&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(dict); } void -MyDerivedClassI::opMyStruct1_async(const Test::MyStruct1& s, +MyDerivedClassI::opMyStruct1_async(Test::MyStruct1 s, function<void (const Test::MyStruct1&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(s); } void -MyDerivedClassI::opMyClass1_async(const shared_ptr<Test::MyClass1>& c, +MyDerivedClassI::opMyClass1_async(shared_ptr<Test::MyClass1> c, function<void (const shared_ptr<Test::MyClass1>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(c); diff --git a/cpp/test/Ice/operations/TestAMDI.h b/cpp/test/Ice/operations/TestAMDI.h index 92fdd4058f1..80911b1cc9d 100644 --- a/cpp/test/Ice/operations/TestAMDI.h +++ b/cpp/test/Ice/operations/TestAMDI.h @@ -12,6 +12,7 @@ #include <IceUtil/Thread.h> #include <TestAMD.h> +#include <TestCommon.h> class MyDerivedClassI : #ifdef ICE_CPP11_MAPPING @@ -27,352 +28,352 @@ public: // // Override the Object "pseudo" operations to verify the operation mode. // - virtual bool ice_isA(const std::string&, const Ice::Current&) const; + virtual bool ice_isA(ICE_IN(std::string), const Ice::Current&) const; virtual void ice_ping(const Ice::Current&) const; virtual std::vector<std::string> ice_ids(const Ice::Current&) const; virtual const std::string& ice_id(const Ice::Current&) const; #ifdef ICE_CPP11_MAPPING virtual void shutdown_async(::std::function<void ()>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void delay_async(Ice::Int, ::std::function<void ()>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void opVoid_async(::std::function<void ()>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void opByte_async(Ice::Byte, Ice::Byte, ::std::function<void (Ice::Byte, Ice::Byte)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void opBool_async(bool, bool, ::std::function<void (bool, bool)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void opShortIntLong_async(short, int, long long int, ::std::function<void (long long int, short, int, long long int)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void opFloatDouble_async(float, double, ::std::function<void (double, float, double)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opString_async(const std::string&, const std::string&, + virtual void opString_async(std::string, std::string, ::std::function<void (const ::std::string&, const ::std::string&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void opMyEnum_async(Test::MyEnum, - ::std::function<void (Test::MyEnum, Test::MyEnum)>, - ::std::function<void (const ::std::exception_ptr&)>, + std::function<void (Test::MyEnum, Test::MyEnum)>, + std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opMyClass_async(const ::std::shared_ptr<Test::MyClassPrx>&, - ::std::function<void (const ::std::shared_ptr<Test::MyClassPrx>&, - const ::std::shared_ptr<Test::MyClassPrx>&, - const ::std::shared_ptr<Test::MyClassPrx>&)>, - ::std::function<void (const ::std::exception_ptr&)>, + virtual void opMyClass_async(std::shared_ptr<Test::MyClassPrx>, + std::function<void (const std::shared_ptr<Test::MyClassPrx>&, + const std::shared_ptr<Test::MyClassPrx>&, + const std::shared_ptr<Test::MyClassPrx>&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opStruct_async(const Test::Structure&, const Test::Structure&, + virtual void opStruct_async(Test::Structure, Test::Structure, ::std::function<void (const Test::Structure&, const Test::Structure&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opByteS_async(const Test::ByteS&, const Test::ByteS&, + virtual void opByteS_async(Test::ByteS, Test::ByteS, ::std::function<void (const Test::ByteS&, const Test::ByteS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opBoolS_async(const Test::BoolS&, const Test::BoolS&, + virtual void opBoolS_async(Test::BoolS, Test::BoolS, ::std::function<void (const Test::BoolS&, const Test::BoolS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opShortIntLongS_async(const Test::ShortS&, const Test::IntS&, const Test::LongS&, + virtual void opShortIntLongS_async(Test::ShortS, Test::IntS, Test::LongS, ::std::function<void (const Test::LongS&, const Test::ShortS&, const Test::IntS&, const Test::LongS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opFloatDoubleS_async(const Test::FloatS&, const Test::DoubleS&, + virtual void opFloatDoubleS_async(Test::FloatS, Test::DoubleS, ::std::function<void (const Test::DoubleS&, const Test::FloatS&, const Test::DoubleS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opStringS_async(const Test::StringS&, const Test::StringS&, + virtual void opStringS_async(Test::StringS, Test::StringS, ::std::function<void (const Test::StringS&, const Test::StringS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opByteSS_async(const Test::ByteSS&, const Test::ByteSS&, + virtual void opByteSS_async(Test::ByteSS, Test::ByteSS, ::std::function<void (const Test::ByteSS&, const Test::ByteSS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opBoolSS_async(const Test::BoolSS&, const Test::BoolSS&, + virtual void opBoolSS_async(Test::BoolSS, Test::BoolSS, ::std::function<void (const Test::BoolSS&, const Test::BoolSS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opShortIntLongSS_async(const Test::ShortSS&, const Test::IntSS&, const Test::LongSS&, + virtual void opShortIntLongSS_async(Test::ShortSS, Test::IntSS, Test::LongSS, ::std::function<void (const Test::LongSS&, const Test::ShortSS&, const Test::IntSS&, const Test::LongSS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opFloatDoubleSS_async(const Test::FloatSS&, const Test::DoubleSS&, + virtual void opFloatDoubleSS_async(Test::FloatSS, Test::DoubleSS, ::std::function<void (const Test::DoubleSS&, const Test::FloatSS&, const Test::DoubleSS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opStringSS_async(const Test::StringSS&, const Test::StringSS&, + virtual void opStringSS_async(Test::StringSS, Test::StringSS, ::std::function<void (const Test::StringSS&, const Test::StringSS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opStringSSS_async(const Test::StringSSS&, const Test::StringSSS&, + virtual void opStringSSS_async(Test::StringSSS, Test::StringSSS, ::std::function<void (const Test::StringSSS&, const Test::StringSSS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opByteBoolD_async(const Test::ByteBoolD&, const Test::ByteBoolD&, + virtual void opByteBoolD_async(Test::ByteBoolD, Test::ByteBoolD, ::std::function<void (const Test::ByteBoolD&, const Test::ByteBoolD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opShortIntD_async(const Test::ShortIntD&, const Test::ShortIntD&, + virtual void opShortIntD_async(Test::ShortIntD, Test::ShortIntD, ::std::function<void (const Test::ShortIntD&, const Test::ShortIntD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opLongFloatD_async(const Test::LongFloatD&, const Test::LongFloatD&, + virtual void opLongFloatD_async(Test::LongFloatD, Test::LongFloatD, ::std::function<void (const Test::LongFloatD&, const Test::LongFloatD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opStringStringD_async(const Test::StringStringD&, const Test::StringStringD&, + virtual void opStringStringD_async(Test::StringStringD, Test::StringStringD, ::std::function<void (const Test::StringStringD&, const Test::StringStringD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opStringMyEnumD_async(const Test::StringMyEnumD&, const Test::StringMyEnumD&, + virtual void opStringMyEnumD_async(Test::StringMyEnumD, Test::StringMyEnumD, ::std::function<void (const Test::StringMyEnumD&, const Test::StringMyEnumD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opMyEnumStringD_async(const Test::MyEnumStringD&, const Test::MyEnumStringD&, + virtual void opMyEnumStringD_async(Test::MyEnumStringD, Test::MyEnumStringD, ::std::function<void (const Test::MyEnumStringD&, const Test::MyEnumStringD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opMyStructMyEnumD_async(const Test::MyStructMyEnumD&, const Test::MyStructMyEnumD&, + virtual void opMyStructMyEnumD_async(Test::MyStructMyEnumD, Test::MyStructMyEnumD, ::std::function<void (const Test::MyStructMyEnumD&, const Test::MyStructMyEnumD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opByteBoolDS_async(const Test::ByteBoolDS&, const Test::ByteBoolDS&, + virtual void opByteBoolDS_async(Test::ByteBoolDS, Test::ByteBoolDS, ::std::function<void (const Test::ByteBoolDS&, const Test::ByteBoolDS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opShortIntDS_async(const Test::ShortIntDS&, const Test::ShortIntDS&, + virtual void opShortIntDS_async(Test::ShortIntDS, Test::ShortIntDS, ::std::function<void (const Test::ShortIntDS&, const Test::ShortIntDS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opLongFloatDS_async(const Test::LongFloatDS&, const Test::LongFloatDS&, + virtual void opLongFloatDS_async(Test::LongFloatDS, Test::LongFloatDS, ::std::function<void (const Test::LongFloatDS&, const Test::LongFloatDS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opStringStringDS_async(const Test::StringStringDS&, const Test::StringStringDS&, + virtual void opStringStringDS_async(Test::StringStringDS, Test::StringStringDS, ::std::function<void (const Test::StringStringDS&, const Test::StringStringDS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opStringMyEnumDS_async(const Test::StringMyEnumDS&, const Test::StringMyEnumDS&, + virtual void opStringMyEnumDS_async(Test::StringMyEnumDS, Test::StringMyEnumDS, ::std::function<void (const Test::StringMyEnumDS&, const Test::StringMyEnumDS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opMyEnumStringDS_async(const Test::MyEnumStringDS&, const Test::MyEnumStringDS&, + virtual void opMyEnumStringDS_async(Test::MyEnumStringDS, Test::MyEnumStringDS, ::std::function<void (const Test::MyEnumStringDS&, const Test::MyEnumStringDS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opMyStructMyEnumDS_async(const Test::MyStructMyEnumDS&, const Test::MyStructMyEnumDS&, + virtual void opMyStructMyEnumDS_async(Test::MyStructMyEnumDS, Test::MyStructMyEnumDS, ::std::function<void (const Test::MyStructMyEnumDS&, const Test::MyStructMyEnumDS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opByteByteSD_async(const Test::ByteByteSD&, const Test::ByteByteSD&, + virtual void opByteByteSD_async(Test::ByteByteSD, Test::ByteByteSD, ::std::function<void (const Test::ByteByteSD&, const Test::ByteByteSD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opBoolBoolSD_async(const Test::BoolBoolSD&, const Test::BoolBoolSD&, + virtual void opBoolBoolSD_async(Test::BoolBoolSD, Test::BoolBoolSD, ::std::function<void (const Test::BoolBoolSD&, const Test::BoolBoolSD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opShortShortSD_async(const Test::ShortShortSD&, const Test::ShortShortSD&, + virtual void opShortShortSD_async(Test::ShortShortSD, Test::ShortShortSD, ::std::function<void (const Test::ShortShortSD&, const Test::ShortShortSD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opIntIntSD_async(const Test::IntIntSD&, const Test::IntIntSD&, + virtual void opIntIntSD_async(Test::IntIntSD, Test::IntIntSD, ::std::function<void (const Test::IntIntSD&, const Test::IntIntSD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opLongLongSD_async(const Test::LongLongSD&, const Test::LongLongSD&, + virtual void opLongLongSD_async(Test::LongLongSD, Test::LongLongSD, ::std::function<void (const Test::LongLongSD&, const Test::LongLongSD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opStringFloatSD_async(const Test::StringFloatSD&, const Test::StringFloatSD&, + virtual void opStringFloatSD_async(Test::StringFloatSD, Test::StringFloatSD, ::std::function<void (const Test::StringFloatSD&, const Test::StringFloatSD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opStringDoubleSD_async(const Test::StringDoubleSD&, const Test::StringDoubleSD&, + virtual void opStringDoubleSD_async(Test::StringDoubleSD, Test::StringDoubleSD, ::std::function<void (const Test::StringDoubleSD&, const Test::StringDoubleSD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opStringStringSD_async(const Test::StringStringSD&, const Test::StringStringSD&, + virtual void opStringStringSD_async(Test::StringStringSD, Test::StringStringSD, ::std::function<void (const Test::StringStringSD&, const Test::StringStringSD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opMyEnumMyEnumSD_async(const Test::MyEnumMyEnumSD&, const Test::MyEnumMyEnumSD&, + virtual void opMyEnumMyEnumSD_async(Test::MyEnumMyEnumSD, Test::MyEnumMyEnumSD, ::std::function<void (const Test::MyEnumMyEnumSD&, const Test::MyEnumMyEnumSD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opIntS_async(const Test::IntS&, + virtual void opIntS_async(Test::IntS, ::std::function<void (const Test::IntS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opByteSOneway_async(const Test::ByteS&, + virtual void opByteSOneway_async(Test::ByteS, ::std::function<void ()>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void opByteSOnewayCallCount_async(::std::function<void (int)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void opContext_async(::std::function<void (const Ice::Context&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opDoubleMarshaling_async(Ice::Double, const Test::DoubleS&, + virtual void opDoubleMarshaling_async(Ice::Double, Test::DoubleS, ::std::function<void ()>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void opIdempotent_async(::std::function<void ()>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void opNonmutating_async(::std::function<void ()>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void opDerived_async(::std::function<void ()>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void opByte1_async(Ice::Byte, ::std::function<void (Ice::Byte)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void opShort1_async(Ice::Short, ::std::function<void (Ice::Short)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void opInt1_async(Ice::Int, ::std::function<void (Ice::Int)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void opLong1_async(Ice::Long, ::std::function<void (Ice::Long)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void opFloat1_async(Ice::Float, ::std::function<void (Ice::Float)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); virtual void opDouble1_async(Ice::Double, ::std::function<void (Ice::Double)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opString1_async(const std::string&, + virtual void opString1_async(std::string, ::std::function<void (const ::std::string&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opStringS1_async(const Test::StringS&, + virtual void opStringS1_async(Test::StringS, ::std::function<void (const Test::StringS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opByteBoolD1_async(const Test::ByteBoolD&, + virtual void opByteBoolD1_async(Test::ByteBoolD, ::std::function<void (const Test::ByteBoolD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opStringS2_async(const Test::StringS&, + virtual void opStringS2_async(Test::StringS, ::std::function<void (const Test::StringS&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opByteBoolD2_async(const Test::ByteBoolD&, + virtual void opByteBoolD2_async(Test::ByteBoolD, ::std::function<void (const Test::ByteBoolD&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opMyStruct1_async(const Test::MyStruct1&, + virtual void opMyStruct1_async(Test::MyStruct1, ::std::function<void (const Test::MyStruct1&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); - virtual void opMyClass1_async(const ::std::shared_ptr<Test::MyClass1>&, + virtual void opMyClass1_async(::std::shared_ptr<Test::MyClass1>, ::std::function<void (const ::std::shared_ptr<Test::MyClass1>&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (std::exception_ptr)>, const Ice::Current&); #else virtual void shutdown_async(const Test::AMD_MyClass_shutdownPtr&, diff --git a/cpp/test/Ice/operations/TestI.cpp b/cpp/test/Ice/operations/TestI.cpp index 53eb7a290ad..c558284ec69 100644 --- a/cpp/test/Ice/operations/TestI.cpp +++ b/cpp/test/Ice/operations/TestI.cpp @@ -16,17 +16,18 @@ using namespace Ice; using namespace Test; +using namespace std; MyDerivedClassI::MyDerivedClassI() : _opByteSOnewayCallCount(0) { } bool -MyDerivedClassI::ice_isA(const std::string& id, const Ice::Current& current) const +MyDerivedClassI::ice_isA(ICE_IN(string) id, const Ice::Current& current) const { test(current.mode == ICE_ENUM(OperationMode, Nonmutating)); #ifdef ICE_CPP11_MAPPING - return Test::MyDerivedClassDisp::ice_isA(id, current); + return Test::MyDerivedClassDisp::ice_isA(move(id), current); #else return Test::MyDerivedClass::ice_isA(id, current); #endif @@ -131,9 +132,9 @@ MyDerivedClassI::opFloatDouble(Ice::Float p1, } std::string -MyDerivedClassI::opString(const std::string& p1, - const std::string& p2, - std::string& p3, +MyDerivedClassI::opString(ICE_IN(string) p1, + ICE_IN(string) p2, + string& p3, const Ice::Current&) { p3 = p2 + " " + p1; @@ -150,7 +151,7 @@ MyDerivedClassI::opMyEnum(Test::MyEnum p1, } Test::MyClassPrxPtr -MyDerivedClassI::opMyClass(const Test::MyClassPrxPtr& p1, +MyDerivedClassI::opMyClass(ICE_IN(Test::MyClassPrxPtr) p1, Test::MyClassPrxPtr& p2, Test::MyClassPrxPtr& p3, const Ice::Current& current) @@ -163,8 +164,8 @@ MyDerivedClassI::opMyClass(const Test::MyClassPrxPtr& p1, } Test::Structure -MyDerivedClassI::opStruct(const Test::Structure& p1, - const ::Test::Structure& p2, +MyDerivedClassI::opStruct(ICE_IN(Test::Structure) p1, + ICE_IN(Test::Structure) p2, ::Test::Structure& p3, const Ice::Current&) { @@ -174,8 +175,8 @@ MyDerivedClassI::opStruct(const Test::Structure& p1, } Test::ByteS -MyDerivedClassI::opByteS(const Test::ByteS& p1, - const Test::ByteS& p2, +MyDerivedClassI::opByteS(ICE_IN(Test::ByteS) p1, + ICE_IN(Test::ByteS) p2, Test::ByteS& p3, const Ice::Current&) { @@ -187,8 +188,8 @@ MyDerivedClassI::opByteS(const Test::ByteS& p1, } Test::BoolS -MyDerivedClassI::opBoolS(const Test::BoolS& p1, - const Test::BoolS& p2, +MyDerivedClassI::opBoolS(ICE_IN(Test::BoolS) p1, + ICE_IN(Test::BoolS) p2, Test::BoolS& p3, const Ice::Current&) { @@ -201,9 +202,9 @@ MyDerivedClassI::opBoolS(const Test::BoolS& p1, } Test::LongS -MyDerivedClassI::opShortIntLongS(const Test::ShortS& p1, - const Test::IntS& p2, - const Test::LongS& p3, +MyDerivedClassI::opShortIntLongS(ICE_IN(Test::ShortS) p1, + ICE_IN(Test::IntS) p2, + ICE_IN(Test::LongS) p3, Test::ShortS& p4, Test::IntS& p5, Test::LongS& p6, @@ -218,8 +219,8 @@ MyDerivedClassI::opShortIntLongS(const Test::ShortS& p1, } Test::DoubleS -MyDerivedClassI::opFloatDoubleS(const Test::FloatS& p1, - const Test::DoubleS& p2, +MyDerivedClassI::opFloatDoubleS(ICE_IN(Test::FloatS) p1, + ICE_IN(Test::DoubleS) p2, Test::FloatS& p3, Test::DoubleS& p4, const Ice::Current&) @@ -233,8 +234,8 @@ MyDerivedClassI::opFloatDoubleS(const Test::FloatS& p1, } Test::StringS -MyDerivedClassI::opStringS(const Test::StringS& p1, - const Test::StringS& p2, +MyDerivedClassI::opStringS(ICE_IN(Test::StringS) p1, + ICE_IN(Test::StringS) p2, Test::StringS& p3, const Ice::Current&) { @@ -247,8 +248,8 @@ MyDerivedClassI::opStringS(const Test::StringS& p1, } Test::ByteSS -MyDerivedClassI::opByteSS(const Test::ByteSS& p1, - const Test::ByteSS& p2, +MyDerivedClassI::opByteSS(ICE_IN(Test::ByteSS) p1, + ICE_IN(Test::ByteSS) p2, Test::ByteSS& p3, const Ice::Current&) { @@ -260,8 +261,8 @@ MyDerivedClassI::opByteSS(const Test::ByteSS& p1, } Test::BoolSS -MyDerivedClassI::opBoolSS(const Test::BoolSS& p1, - const Test::BoolSS& p2, +MyDerivedClassI::opBoolSS(ICE_IN(Test::BoolSS) p1, + ICE_IN(Test::BoolSS) p2, Test::BoolSS& p3, const Ice::Current&) { @@ -274,9 +275,9 @@ MyDerivedClassI::opBoolSS(const Test::BoolSS& p1, } Test::LongSS -MyDerivedClassI::opShortIntLongSS(const Test::ShortSS& p1, - const Test::IntSS& p2, - const Test::LongSS& p3, +MyDerivedClassI::opShortIntLongSS(ICE_IN(Test::ShortSS) p1, + ICE_IN(Test::IntSS) p2, + ICE_IN(Test::LongSS) p3, Test::ShortSS& p4, Test::IntSS& p5, Test::LongSS& p6, @@ -291,8 +292,8 @@ MyDerivedClassI::opShortIntLongSS(const Test::ShortSS& p1, } Test::DoubleSS -MyDerivedClassI::opFloatDoubleSS(const Test::FloatSS& p1, - const Test::DoubleSS& p2, +MyDerivedClassI::opFloatDoubleSS(ICE_IN(Test::FloatSS) p1, + ICE_IN(Test::DoubleSS) p2, Test::FloatSS& p3, Test::DoubleSS& p4, const Ice::Current&) @@ -306,8 +307,8 @@ MyDerivedClassI::opFloatDoubleSS(const Test::FloatSS& p1, } Test::StringSS -MyDerivedClassI::opStringSS(const Test::StringSS& p1, - const Test::StringSS& p2, +MyDerivedClassI::opStringSS(ICE_IN(Test::StringSS) p1, + ICE_IN(Test::StringSS) p2, Test::StringSS& p3, const Ice::Current&) { @@ -320,8 +321,8 @@ MyDerivedClassI::opStringSS(const Test::StringSS& p1, } Test::StringSSS -MyDerivedClassI::opStringSSS(const Test::StringSSS& p1, - const Test::StringSSS& p2, +MyDerivedClassI::opStringSSS(ICE_IN(Test::StringSSS) p1, + ICE_IN(Test::StringSSS) p2, Test::StringSSS& p3, const ::Ice::Current&) { @@ -334,8 +335,8 @@ MyDerivedClassI::opStringSSS(const Test::StringSSS& p1, } Test::ByteBoolD -MyDerivedClassI::opByteBoolD(const Test::ByteBoolD& p1, - const Test::ByteBoolD& p2, +MyDerivedClassI::opByteBoolD(ICE_IN(Test::ByteBoolD) p1, + ICE_IN(Test::ByteBoolD) p2, Test::ByteBoolD& p3, const Ice::Current&) { @@ -346,8 +347,8 @@ MyDerivedClassI::opByteBoolD(const Test::ByteBoolD& p1, } Test::ShortIntD -MyDerivedClassI::opShortIntD(const Test::ShortIntD& p1, - const Test::ShortIntD& p2, +MyDerivedClassI::opShortIntD(ICE_IN(Test::ShortIntD) p1, + ICE_IN(Test::ShortIntD) p2, Test::ShortIntD& p3, const Ice::Current&) { @@ -358,8 +359,8 @@ MyDerivedClassI::opShortIntD(const Test::ShortIntD& p1, } Test::LongFloatD -MyDerivedClassI::opLongFloatD(const Test::LongFloatD& p1, - const Test::LongFloatD& p2, +MyDerivedClassI::opLongFloatD(ICE_IN(Test::LongFloatD) p1, + ICE_IN(Test::LongFloatD) p2, Test::LongFloatD& p3, const Ice::Current&) { @@ -370,8 +371,8 @@ MyDerivedClassI::opLongFloatD(const Test::LongFloatD& p1, } Test::StringStringD -MyDerivedClassI::opStringStringD(const Test::StringStringD& p1, - const Test::StringStringD& p2, +MyDerivedClassI::opStringStringD(ICE_IN(Test::StringStringD) p1, + ICE_IN(Test::StringStringD) p2, Test::StringStringD& p3, const Ice::Current&) { @@ -382,8 +383,8 @@ MyDerivedClassI::opStringStringD(const Test::StringStringD& p1, } Test::StringMyEnumD -MyDerivedClassI::opStringMyEnumD(const Test::StringMyEnumD& p1, - const Test::StringMyEnumD& p2, +MyDerivedClassI::opStringMyEnumD(ICE_IN(Test::StringMyEnumD) p1, + ICE_IN(Test::StringMyEnumD) p2, Test::StringMyEnumD& p3, const Ice::Current&) { @@ -394,8 +395,8 @@ MyDerivedClassI::opStringMyEnumD(const Test::StringMyEnumD& p1, } Test::MyEnumStringD -MyDerivedClassI::opMyEnumStringD(const Test::MyEnumStringD& p1, - const Test::MyEnumStringD& p2, +MyDerivedClassI::opMyEnumStringD(ICE_IN(Test::MyEnumStringD) p1, + ICE_IN(Test::MyEnumStringD) p2, Test::MyEnumStringD& p3, const Ice::Current&) { @@ -406,8 +407,8 @@ MyDerivedClassI::opMyEnumStringD(const Test::MyEnumStringD& p1, } Test::MyStructMyEnumD -MyDerivedClassI::opMyStructMyEnumD(const Test::MyStructMyEnumD& p1, - const Test::MyStructMyEnumD& p2, +MyDerivedClassI::opMyStructMyEnumD(ICE_IN(Test::MyStructMyEnumD) p1, + ICE_IN(Test::MyStructMyEnumD) p2, Test::MyStructMyEnumD& p3, const Ice::Current&) { @@ -418,8 +419,8 @@ MyDerivedClassI::opMyStructMyEnumD(const Test::MyStructMyEnumD& p1, } Test::ByteBoolDS -MyDerivedClassI::opByteBoolDS(const Test::ByteBoolDS& p1, - const Test::ByteBoolDS& p2, +MyDerivedClassI::opByteBoolDS(ICE_IN(Test::ByteBoolDS) p1, + ICE_IN(Test::ByteBoolDS) p2, Test::ByteBoolDS& p3, const Ice::Current&) { @@ -432,10 +433,10 @@ MyDerivedClassI::opByteBoolDS(const Test::ByteBoolDS& p1, } Test::ShortIntDS -MyDerivedClassI::opShortIntDS(const Test::ShortIntDS& p1, - const Test::ShortIntDS& p2, - Test::ShortIntDS& p3, - const Ice::Current&) +MyDerivedClassI::opShortIntDS(ICE_IN(Test::ShortIntDS) p1, + ICE_IN(Test::ShortIntDS) p2, + Test::ShortIntDS& p3, + const Ice::Current&) { p3 = p2; std::copy(p1.begin(), p1.end(), std::back_inserter(p3)); @@ -446,10 +447,10 @@ MyDerivedClassI::opShortIntDS(const Test::ShortIntDS& p1, } Test::LongFloatDS -MyDerivedClassI::opLongFloatDS(const Test::LongFloatDS& p1, - const Test::LongFloatDS& p2, - Test::LongFloatDS& p3, - const Ice::Current&) +MyDerivedClassI::opLongFloatDS(ICE_IN(Test::LongFloatDS) p1, + ICE_IN(Test::LongFloatDS) p2, + Test::LongFloatDS& p3, + const Ice::Current&) { p3 = p2; std::copy(p1.begin(), p1.end(), std::back_inserter(p3)); @@ -460,10 +461,10 @@ MyDerivedClassI::opLongFloatDS(const Test::LongFloatDS& p1, } Test::StringStringDS -MyDerivedClassI::opStringStringDS(const Test::StringStringDS& p1, - const Test::StringStringDS& p2, - Test::StringStringDS& p3, - const Ice::Current&) +MyDerivedClassI::opStringStringDS(ICE_IN(Test::StringStringDS) p1, + ICE_IN(Test::StringStringDS) p2, + Test::StringStringDS& p3, + const Ice::Current&) { p3 = p2; std::copy(p1.begin(), p1.end(), std::back_inserter(p3)); @@ -474,10 +475,10 @@ MyDerivedClassI::opStringStringDS(const Test::StringStringDS& p1, } Test::StringMyEnumDS -MyDerivedClassI::opStringMyEnumDS(const Test::StringMyEnumDS& p1, - const Test::StringMyEnumDS& p2, - Test::StringMyEnumDS& p3, - const Ice::Current&) +MyDerivedClassI::opStringMyEnumDS(ICE_IN(Test::StringMyEnumDS) p1, + ICE_IN(Test::StringMyEnumDS) p2, + Test::StringMyEnumDS& p3, + const Ice::Current&) { p3 = p2; std::copy(p1.begin(), p1.end(), std::back_inserter(p3)); @@ -488,10 +489,10 @@ MyDerivedClassI::opStringMyEnumDS(const Test::StringMyEnumDS& p1, } Test::MyEnumStringDS -MyDerivedClassI::opMyEnumStringDS(const Test::MyEnumStringDS& p1, - const Test::MyEnumStringDS& p2, - Test::MyEnumStringDS& p3, - const Ice::Current&) +MyDerivedClassI::opMyEnumStringDS(ICE_IN(Test::MyEnumStringDS) p1, + ICE_IN(Test::MyEnumStringDS) p2, + Test::MyEnumStringDS& p3, + const Ice::Current&) { p3 = p2; std::copy(p1.begin(), p1.end(), std::back_inserter(p3)); @@ -502,10 +503,10 @@ MyDerivedClassI::opMyEnumStringDS(const Test::MyEnumStringDS& p1, } Test::MyStructMyEnumDS -MyDerivedClassI::opMyStructMyEnumDS(const Test::MyStructMyEnumDS& p1, - const Test::MyStructMyEnumDS& p2, - Test::MyStructMyEnumDS& p3, - const Ice::Current&) +MyDerivedClassI::opMyStructMyEnumDS(ICE_IN(Test::MyStructMyEnumDS) p1, + ICE_IN(Test::MyStructMyEnumDS) p2, + Test::MyStructMyEnumDS& p3, + const Ice::Current&) { p3 = p2; std::copy(p1.begin(), p1.end(), std::back_inserter(p3)); @@ -516,8 +517,8 @@ MyDerivedClassI::opMyStructMyEnumDS(const Test::MyStructMyEnumDS& p1, } Test::ByteByteSD -MyDerivedClassI::opByteByteSD(const Test::ByteByteSD& p1, - const Test::ByteByteSD& p2, +MyDerivedClassI::opByteByteSD(ICE_IN(Test::ByteByteSD) p1, + ICE_IN(Test::ByteByteSD) p2, Test::ByteByteSD& p3, const Ice::Current&) { @@ -528,8 +529,8 @@ MyDerivedClassI::opByteByteSD(const Test::ByteByteSD& p1, } Test::BoolBoolSD -MyDerivedClassI::opBoolBoolSD(const Test::BoolBoolSD& p1, - const Test::BoolBoolSD& p2, +MyDerivedClassI::opBoolBoolSD(ICE_IN(Test::BoolBoolSD) p1, + ICE_IN(Test::BoolBoolSD) p2, Test::BoolBoolSD& p3, const Ice::Current&) { @@ -540,8 +541,8 @@ MyDerivedClassI::opBoolBoolSD(const Test::BoolBoolSD& p1, } Test::ShortShortSD -MyDerivedClassI::opShortShortSD(const Test::ShortShortSD& p1, - const Test::ShortShortSD& p2, +MyDerivedClassI::opShortShortSD(ICE_IN(Test::ShortShortSD) p1, + ICE_IN(Test::ShortShortSD) p2, Test::ShortShortSD& p3, const Ice::Current&) { @@ -552,8 +553,8 @@ MyDerivedClassI::opShortShortSD(const Test::ShortShortSD& p1, } Test::IntIntSD -MyDerivedClassI::opIntIntSD(const Test::IntIntSD& p1, - const Test::IntIntSD& p2, +MyDerivedClassI::opIntIntSD(ICE_IN(Test::IntIntSD) p1, + ICE_IN(Test::IntIntSD) p2, Test::IntIntSD& p3, const Ice::Current&) { @@ -564,8 +565,8 @@ MyDerivedClassI::opIntIntSD(const Test::IntIntSD& p1, } Test::LongLongSD -MyDerivedClassI::opLongLongSD(const Test::LongLongSD& p1, - const Test::LongLongSD& p2, +MyDerivedClassI::opLongLongSD(ICE_IN(Test::LongLongSD) p1, + ICE_IN(Test::LongLongSD) p2, Test::LongLongSD& p3, const Ice::Current&) { @@ -576,10 +577,10 @@ MyDerivedClassI::opLongLongSD(const Test::LongLongSD& p1, } Test::StringFloatSD -MyDerivedClassI::opStringFloatSD(const Test::StringFloatSD& p1, - const Test::StringFloatSD& p2, - Test::StringFloatSD& p3, - const Ice::Current&) +MyDerivedClassI::opStringFloatSD(ICE_IN(Test::StringFloatSD) p1, + ICE_IN(Test::StringFloatSD) p2, + Test::StringFloatSD& p3, + const Ice::Current&) { p3 = p2; Test::StringFloatSD r = p1; @@ -588,8 +589,8 @@ MyDerivedClassI::opStringFloatSD(const Test::StringFloatSD& p1, } Test::StringDoubleSD -MyDerivedClassI::opStringDoubleSD(const Test::StringDoubleSD& p1, - const Test::StringDoubleSD& p2, +MyDerivedClassI::opStringDoubleSD(ICE_IN(Test::StringDoubleSD) p1, + ICE_IN(Test::StringDoubleSD) p2, Test::StringDoubleSD& p3, const Ice::Current&) { @@ -600,8 +601,8 @@ MyDerivedClassI::opStringDoubleSD(const Test::StringDoubleSD& p1, } Test::StringStringSD -MyDerivedClassI::opStringStringSD(const Test::StringStringSD& p1, - const Test::StringStringSD& p2, +MyDerivedClassI::opStringStringSD(ICE_IN(Test::StringStringSD) p1, + ICE_IN(Test::StringStringSD) p2, Test::StringStringSD& p3, const Ice::Current&) { @@ -612,10 +613,10 @@ MyDerivedClassI::opStringStringSD(const Test::StringStringSD& p1, } Test::MyEnumMyEnumSD -MyDerivedClassI::opMyEnumMyEnumSD(const Test::MyEnumMyEnumSD& p1, - const Test::MyEnumMyEnumSD& p2, - Test::MyEnumMyEnumSD& p3, - const Ice::Current&) +MyDerivedClassI::opMyEnumMyEnumSD(ICE_IN(Test::MyEnumMyEnumSD) p1, + ICE_IN(Test::MyEnumMyEnumSD) p2, + Test::MyEnumMyEnumSD& p3, + const Ice::Current&) { p3 = p2; Test::MyEnumMyEnumSD r = p1; @@ -624,7 +625,7 @@ MyDerivedClassI::opMyEnumMyEnumSD(const Test::MyEnumMyEnumSD& p1, } Test::IntS -MyDerivedClassI::opIntS(const Test::IntS& s, const Ice::Current&) +MyDerivedClassI::opIntS(ICE_IN(Test::IntS) s, const Ice::Current&) { Test::IntS r; std::transform(s.begin(), s.end(), std::back_inserter(r), std::negate<int>()); @@ -632,7 +633,7 @@ MyDerivedClassI::opIntS(const Test::IntS& s, const Ice::Current&) } void -MyDerivedClassI::opByteSOneway(const Test::ByteS&, const Ice::Current&) +MyDerivedClassI::opByteSOneway(ICE_IN(Test::ByteS), const Ice::Current&) { IceUtil::Mutex::Lock sync(_mutex); ++_opByteSOnewayCallCount; @@ -654,7 +655,7 @@ MyDerivedClassI::opContext(const Ice::Current& c) } void -MyDerivedClassI::opDoubleMarshaling(Ice::Double p1, const Test::DoubleS& p2, const Ice::Current&) +MyDerivedClassI::opDoubleMarshaling(Ice::Double p1, ICE_IN(Test::DoubleS) p2, const Ice::Current&) { Ice::Double d = 1278312346.0 / 13.0; test(p1 == d); @@ -718,43 +719,43 @@ MyDerivedClassI::opDouble1(Ice::Double d, const Ice::Current&) } std::string -MyDerivedClassI::opString1(const std::string& s, const Ice::Current&) +MyDerivedClassI::opString1(ICE_IN(string) s, const Ice::Current&) { return s; } Test::StringS -MyDerivedClassI::opStringS1(const Test::StringS& seq, const Ice::Current&) +MyDerivedClassI::opStringS1(ICE_IN(Test::StringS) seq, const Ice::Current&) { return seq; } Test::ByteBoolD -MyDerivedClassI::opByteBoolD1(const Test::ByteBoolD& dict, const Ice::Current&) +MyDerivedClassI::opByteBoolD1(ICE_IN(Test::ByteBoolD) dict, const Ice::Current&) { return dict; } Test::StringS -MyDerivedClassI::opStringS2(const Test::StringS& seq, const Ice::Current&) +MyDerivedClassI::opStringS2(ICE_IN(Test::StringS) seq, const Ice::Current&) { return seq; } Test::ByteBoolD -MyDerivedClassI::opByteBoolD2(const Test::ByteBoolD& dict, const Ice::Current&) +MyDerivedClassI::opByteBoolD2(ICE_IN(Test::ByteBoolD) dict, const Ice::Current&) { return dict; } Test::MyStruct1 -MyDerivedClassI::opMyStruct1(const Test::MyStruct1& s, const Ice::Current&) +MyDerivedClassI::opMyStruct1(ICE_IN(Test::MyStruct1) s, const Ice::Current&) { return s; } Test::MyClass1Ptr -MyDerivedClassI::opMyClass1(const Test::MyClass1Ptr& c, const Ice::Current&) +MyDerivedClassI::opMyClass1(ICE_IN(Test::MyClass1Ptr) c, const Ice::Current&) { return c; } diff --git a/cpp/test/Ice/operations/TestI.h b/cpp/test/Ice/operations/TestI.h index 9a5dc24fe59..12d52327c8c 100644 --- a/cpp/test/Ice/operations/TestI.h +++ b/cpp/test/Ice/operations/TestI.h @@ -11,6 +11,7 @@ #define TEST_I_H #include <Test.h> +#include <TestCommon.h> class MyDerivedClassI : #ifdef ICE_CPP11_MAPPING @@ -26,7 +27,7 @@ public: // // Override the Object "pseudo" operations to verify the operation mode. // - virtual bool ice_isA(const std::string&, const Ice::Current&) const; + virtual bool ice_isA(ICE_IN(std::string), const Ice::Current&) const; virtual void ice_ping(const Ice::Current&) const; virtual std::vector<std::string> ice_ids(const Ice::Current&) const; virtual const std::string& ice_id(const Ice::Current&) const; @@ -61,8 +62,8 @@ public: Ice::Double&, const Ice::Current&); - virtual std::string opString(const std::string&, - const std::string&, + virtual std::string opString(ICE_IN(std::string), + ICE_IN(std::string), std::string&, const Ice::Current&); @@ -70,177 +71,201 @@ public: Test::MyEnum&, const Ice::Current&); - virtual Test::MyClassPrxPtr opMyClass(const Test::MyClassPrxPtr&, + virtual Test::MyClassPrxPtr opMyClass(ICE_IN(Test::MyClassPrxPtr), Test::MyClassPrxPtr&, Test::MyClassPrxPtr&, const Ice::Current&); - virtual Test::Structure opStruct(const Test::Structure&, const Test::Structure&, - Test::Structure&, - const Ice::Current&); + virtual Test::Structure opStruct(ICE_IN(Test::Structure), + ICE_IN(Test::Structure), + Test::Structure&, + const Ice::Current&); - virtual Test::ByteS opByteS(const Test::ByteS&, - const Test::ByteS&, + virtual Test::ByteS opByteS(ICE_IN(Test::ByteS), + ICE_IN(Test::ByteS), Test::ByteS&, const Ice::Current&); - virtual Test::BoolS opBoolS(const Test::BoolS&, - const Test::BoolS&, + virtual Test::BoolS opBoolS(ICE_IN(Test::BoolS), + ICE_IN(Test::BoolS), Test::BoolS&, const Ice::Current&); - virtual Test::LongS opShortIntLongS(const Test::ShortS&, - const Test::IntS&, - const Test::LongS&, + virtual Test::LongS opShortIntLongS(ICE_IN(Test::ShortS), + ICE_IN(Test::IntS), + ICE_IN(Test::LongS), Test::ShortS&, Test::IntS&, Test::LongS&, const Ice::Current&); - virtual Test::DoubleS opFloatDoubleS(const Test::FloatS&, - const Test::DoubleS&, + virtual Test::DoubleS opFloatDoubleS(ICE_IN(Test::FloatS), + ICE_IN(Test::DoubleS), Test::FloatS&, Test::DoubleS&, const Ice::Current&); - virtual Test::StringS opStringS(const Test::StringS&, - const Test::StringS&, + virtual Test::StringS opStringS(ICE_IN(Test::StringS), + ICE_IN(Test::StringS), Test::StringS&, const Ice::Current&); - virtual Test::ByteSS opByteSS(const Test::ByteSS&, - const Test::ByteSS&, + virtual Test::ByteSS opByteSS(ICE_IN(Test::ByteSS), + ICE_IN(Test::ByteSS), Test::ByteSS&, const Ice::Current&); - virtual Test::BoolSS opBoolSS(const Test::BoolSS&, - const Test::BoolSS&, + virtual Test::BoolSS opBoolSS(ICE_IN(Test::BoolSS), + ICE_IN(Test::BoolSS), Test::BoolSS&, const Ice::Current&); - virtual Test::LongSS opShortIntLongSS(const Test::ShortSS&, - const Test::IntSS&, - const Test::LongSS&, + virtual Test::LongSS opShortIntLongSS(ICE_IN(Test::ShortSS), + ICE_IN(Test::IntSS), + ICE_IN(Test::LongSS), Test::ShortSS&, Test::IntSS&, Test::LongSS&, const Ice::Current&); - virtual Test::DoubleSS opFloatDoubleSS(const Test::FloatSS&, - const Test::DoubleSS&, + virtual Test::DoubleSS opFloatDoubleSS(ICE_IN(Test::FloatSS), + ICE_IN(Test::DoubleSS), Test::FloatSS&, Test::DoubleSS&, const Ice::Current&); - virtual Test::StringSS opStringSS(const Test::StringSS&, - const Test::StringSS&, + virtual Test::StringSS opStringSS(ICE_IN(Test::StringSS), + ICE_IN(Test::StringSS), Test::StringSS&, const Ice::Current&); - virtual Test::StringSSS opStringSSS(const Test::StringSSS&, - const Test::StringSSS&, + virtual Test::StringSSS opStringSSS(ICE_IN(Test::StringSSS), + ICE_IN(Test::StringSSS), Test::StringSSS&, const ::Ice::Current&); - virtual Test::ByteBoolD opByteBoolD(const Test::ByteBoolD&, const Test::ByteBoolD&, + virtual Test::ByteBoolD opByteBoolD(ICE_IN(Test::ByteBoolD), + ICE_IN(Test::ByteBoolD), Test::ByteBoolD&, const Ice::Current&); - virtual Test::ShortIntD opShortIntD(const Test::ShortIntD&, const Test::ShortIntD&, + virtual Test::ShortIntD opShortIntD(ICE_IN(Test::ShortIntD), + ICE_IN(Test::ShortIntD), Test::ShortIntD&, const Ice::Current&); - virtual Test::LongFloatD opLongFloatD(const Test::LongFloatD&, const Test::LongFloatD&, + virtual Test::LongFloatD opLongFloatD(ICE_IN(Test::LongFloatD), + ICE_IN(Test::LongFloatD), Test::LongFloatD&, const Ice::Current&); - virtual Test::StringStringD opStringStringD(const Test::StringStringD&, const Test::StringStringD&, + virtual Test::StringStringD opStringStringD(ICE_IN(Test::StringStringD), + ICE_IN(Test::StringStringD), Test::StringStringD&, const Ice::Current&); - virtual Test::StringMyEnumD opStringMyEnumD(const Test::StringMyEnumD&, const Test::StringMyEnumD&, + virtual Test::StringMyEnumD opStringMyEnumD(ICE_IN(Test::StringMyEnumD), + ICE_IN(Test::StringMyEnumD), Test::StringMyEnumD&, const Ice::Current&); - virtual Test::MyEnumStringD opMyEnumStringD(const Test::MyEnumStringD&, const Test::MyEnumStringD&, + virtual Test::MyEnumStringD opMyEnumStringD(ICE_IN(Test::MyEnumStringD), + ICE_IN(Test::MyEnumStringD), Test::MyEnumStringD&, const Ice::Current&); - virtual Test::MyStructMyEnumD opMyStructMyEnumD(const Test::MyStructMyEnumD&, const Test::MyStructMyEnumD&, + virtual Test::MyStructMyEnumD opMyStructMyEnumD(ICE_IN(Test::MyStructMyEnumD), + ICE_IN(Test::MyStructMyEnumD), Test::MyStructMyEnumD&, const Ice::Current&); - virtual Test::ByteBoolDS opByteBoolDS(const Test::ByteBoolDS&, const Test::ByteBoolDS&, + virtual Test::ByteBoolDS opByteBoolDS(ICE_IN(Test::ByteBoolDS), + ICE_IN(Test::ByteBoolDS), Test::ByteBoolDS&, const Ice::Current&); - virtual Test::ShortIntDS opShortIntDS(const Test::ShortIntDS&, const Test::ShortIntDS&, + virtual Test::ShortIntDS opShortIntDS(ICE_IN(Test::ShortIntDS), + ICE_IN(Test::ShortIntDS), Test::ShortIntDS&, const Ice::Current&); - virtual Test::LongFloatDS opLongFloatDS(const Test::LongFloatDS&, const Test::LongFloatDS&, + virtual Test::LongFloatDS opLongFloatDS(ICE_IN(Test::LongFloatDS), + ICE_IN(Test::LongFloatDS), Test::LongFloatDS&, const Ice::Current&); - virtual Test::StringStringDS opStringStringDS(const Test::StringStringDS&, const Test::StringStringDS&, + virtual Test::StringStringDS opStringStringDS(ICE_IN(Test::StringStringDS), + ICE_IN(Test::StringStringDS), Test::StringStringDS&, const Ice::Current&); - virtual Test::StringMyEnumDS opStringMyEnumDS(const Test::StringMyEnumDS&, const Test::StringMyEnumDS&, + virtual Test::StringMyEnumDS opStringMyEnumDS(ICE_IN(Test::StringMyEnumDS), + ICE_IN(Test::StringMyEnumDS), Test::StringMyEnumDS&, const Ice::Current&); - virtual Test::MyStructMyEnumDS opMyStructMyEnumDS(const Test::MyStructMyEnumDS&, const Test::MyStructMyEnumDS&, + virtual Test::MyStructMyEnumDS opMyStructMyEnumDS(ICE_IN(Test::MyStructMyEnumDS), + ICE_IN(Test::MyStructMyEnumDS), Test::MyStructMyEnumDS&, const Ice::Current&); - virtual Test::MyEnumStringDS opMyEnumStringDS(const Test::MyEnumStringDS&, const Test::MyEnumStringDS&, + virtual Test::MyEnumStringDS opMyEnumStringDS(ICE_IN(Test::MyEnumStringDS), + ICE_IN(Test::MyEnumStringDS), Test::MyEnumStringDS&, const Ice::Current&); - virtual Test::ByteByteSD opByteByteSD(const Test::ByteByteSD&, const Test::ByteByteSD&, + virtual Test::ByteByteSD opByteByteSD(ICE_IN(Test::ByteByteSD), + ICE_IN(Test::ByteByteSD), Test::ByteByteSD&, const Ice::Current&); - virtual Test::BoolBoolSD opBoolBoolSD(const Test::BoolBoolSD&, const Test::BoolBoolSD&, + virtual Test::BoolBoolSD opBoolBoolSD(ICE_IN(Test::BoolBoolSD), + ICE_IN(Test::BoolBoolSD), Test::BoolBoolSD&, const Ice::Current&); - virtual Test::ShortShortSD opShortShortSD(const Test::ShortShortSD&, const Test::ShortShortSD&, + virtual Test::ShortShortSD opShortShortSD(ICE_IN(Test::ShortShortSD), + ICE_IN(Test::ShortShortSD), Test::ShortShortSD&, const Ice::Current&); - virtual Test::IntIntSD opIntIntSD(const Test::IntIntSD&, const Test::IntIntSD&, + virtual Test::IntIntSD opIntIntSD(ICE_IN(Test::IntIntSD), + ICE_IN(Test::IntIntSD), Test::IntIntSD&, const Ice::Current&); - virtual Test::LongLongSD opLongLongSD(const Test::LongLongSD&, const Test::LongLongSD&, + virtual Test::LongLongSD opLongLongSD(ICE_IN(Test::LongLongSD), + ICE_IN(Test::LongLongSD), Test::LongLongSD&, const Ice::Current&); - virtual Test::StringFloatSD opStringFloatSD(const Test::StringFloatSD&, const Test::StringFloatSD&, + virtual Test::StringFloatSD opStringFloatSD(ICE_IN(Test::StringFloatSD), + ICE_IN(Test::StringFloatSD), Test::StringFloatSD&, const Ice::Current&); - virtual Test::StringDoubleSD opStringDoubleSD(const Test::StringDoubleSD&, const Test::StringDoubleSD&, + virtual Test::StringDoubleSD opStringDoubleSD(ICE_IN(Test::StringDoubleSD), + ICE_IN(Test::StringDoubleSD), Test::StringDoubleSD&, const Ice::Current&); - virtual Test::StringStringSD opStringStringSD(const Test::StringStringSD&, const Test::StringStringSD&, + virtual Test::StringStringSD opStringStringSD(ICE_IN(Test::StringStringSD), + ICE_IN(Test::StringStringSD), Test::StringStringSD&, const Ice::Current&); - virtual Test::MyEnumMyEnumSD opMyEnumMyEnumSD(const Test::MyEnumMyEnumSD&, const Test::MyEnumMyEnumSD&, + virtual Test::MyEnumMyEnumSD opMyEnumMyEnumSD(ICE_IN(Test::MyEnumMyEnumSD), + ICE_IN(Test::MyEnumMyEnumSD), Test::MyEnumMyEnumSD&, const Ice::Current&); - virtual Test::IntS opIntS(const Test::IntS&, const Ice::Current&); + virtual Test::IntS opIntS(ICE_IN(Test::IntS), const Ice::Current&); - virtual void opByteSOneway(const Test::ByteS&, const Ice::Current&); + virtual void opByteSOneway(ICE_IN(Test::ByteS), const Ice::Current&); virtual int opByteSOnewayCallCount(const Ice::Current&); virtual Ice::Context opContext(const Ice::Current&); - virtual void opDoubleMarshaling(Ice::Double, const Test::DoubleS&, const Ice::Current&); + virtual void opDoubleMarshaling(Ice::Double, ICE_IN(Test::DoubleS), const Ice::Current&); virtual void opIdempotent(const Ice::Current&); @@ -260,19 +285,19 @@ public: virtual Ice::Double opDouble1(Ice::Double, const Ice::Current&); - virtual std::string opString1(const std::string&, const Ice::Current&); + virtual std::string opString1(ICE_IN(std::string), const Ice::Current&); - virtual Test::StringS opStringS1(const Test::StringS&, const Ice::Current&); + virtual Test::StringS opStringS1(ICE_IN(Test::StringS), const Ice::Current&); - virtual Test::ByteBoolD opByteBoolD1(const Test::ByteBoolD&, const Ice::Current&); + virtual Test::ByteBoolD opByteBoolD1(ICE_IN(Test::ByteBoolD), const Ice::Current&); - virtual Test::StringS opStringS2(const Test::StringS&, const Ice::Current&); + virtual Test::StringS opStringS2(ICE_IN(Test::StringS), const Ice::Current&); - virtual Test::ByteBoolD opByteBoolD2(const Test::ByteBoolD&, const Ice::Current&); + virtual Test::ByteBoolD opByteBoolD2(ICE_IN(Test::ByteBoolD), const Ice::Current&); - virtual Test::MyStruct1 opMyStruct1(const Test::MyStruct1&, const Ice::Current&); + virtual Test::MyStruct1 opMyStruct1(ICE_IN(Test::MyStruct1), const Ice::Current&); - virtual Test::MyClass1Ptr opMyClass1(const Test::MyClass1Ptr&, const Ice::Current&); + virtual Test::MyClass1Ptr opMyClass1(ICE_IN(Test::MyClass1Ptr), const Ice::Current&); private: diff --git a/cpp/test/Ice/proxy/TestAMDI.cpp b/cpp/test/Ice/proxy/TestAMDI.cpp index 54098ebd7ae..e5abfdbf2af 100644 --- a/cpp/test/Ice/proxy/TestAMDI.cpp +++ b/cpp/test/Ice/proxy/TestAMDI.cpp @@ -20,9 +20,9 @@ MyDerivedClassI::MyDerivedClassI() #ifdef ICE_CPP11_MAPPING void MyDerivedClassI::echo_async( - const shared_ptr<Ice::ObjectPrx>& obj, + shared_ptr<Ice::ObjectPrx> obj, function<void (const shared_ptr<Ice::ObjectPrx>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(obj); @@ -31,7 +31,7 @@ MyDerivedClassI::echo_async( void MyDerivedClassI::shutdown_async( function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current& current) { current.adapter->getCommunicator()->shutdown(); @@ -41,11 +41,17 @@ MyDerivedClassI::shutdown_async( void MyDerivedClassI::getContext_async( function<void (const Ice::Context&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) { response(_ctx); } +bool +MyDerivedClassI::ice_isA(string s, const Ice::Current& current) const +{ + _ctx = current.ctx; + return Test::MyDerivedClassDisp::ice_isA(move(s), current); +} #else void MyDerivedClassI::echo_async(const Test::AMD_MyDerivedClass_echoPtr& cb, const Ice::ObjectPrx& obj, const Ice::Current&) @@ -65,14 +71,12 @@ MyDerivedClassI::getContext_async(const Test::AMD_MyClass_getContextPtr& cb, con { cb->ice_response(_ctx); } -#endif + bool MyDerivedClassI::ice_isA(const string& s, const Ice::Current& current) const { _ctx = current.ctx; -#ifdef ICE_CPP11_MAPPING - return Test::MyDerivedClassDisp::ice_isA(s, current); -#else return Test::MyDerivedClass::ice_isA(s, current); -#endif } + +#endif diff --git a/cpp/test/Ice/proxy/TestAMDI.h b/cpp/test/Ice/proxy/TestAMDI.h index b3400f4f83d..caf9b4d9f82 100644 --- a/cpp/test/Ice/proxy/TestAMDI.h +++ b/cpp/test/Ice/proxy/TestAMDI.h @@ -25,28 +25,30 @@ public: #ifdef ICE_CPP11_MAPPING virtual void echo_async( - const std::shared_ptr<Ice::ObjectPrx>&, + std::shared_ptr<Ice::ObjectPrx>, ::std::function<void (const ::std::shared_ptr<Ice::ObjectPrx>&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (::std::exception_ptr)>, const Ice::Current&); virtual void shutdown_async( ::std::function<void ()>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (::std::exception_ptr)>, const Ice::Current&); virtual void getContext_async( ::std::function<void (const Ice::Context&)>, - ::std::function<void (const ::std::exception_ptr&)>, + ::std::function<void (::std::exception_ptr)>, const Ice::Current&); + + virtual bool ice_isA(std::string, const Ice::Current&) const; #else virtual void echo_async(const Test::AMD_MyDerivedClass_echoPtr&, const Ice::ObjectPrx&, const Ice::Current&); virtual void shutdown_async(const Test::AMD_MyClass_shutdownPtr&, const Ice::Current&); virtual void getContext_async(const Test::AMD_MyClass_getContextPtr& cb, const Ice::Current&); -#endif virtual bool ice_isA(const std::string&, const Ice::Current&) const; +#endif private: mutable Ice::Context _ctx; diff --git a/cpp/test/Ice/proxy/TestI.cpp b/cpp/test/Ice/proxy/TestI.cpp index 7ffde953fad..485b84576bd 100644 --- a/cpp/test/Ice/proxy/TestI.cpp +++ b/cpp/test/Ice/proxy/TestI.cpp @@ -17,11 +17,19 @@ MyDerivedClassI::MyDerivedClassI() { } -Ice::ObjectPrxPtr -MyDerivedClassI::echo(const Ice::ObjectPrxPtr& obj, const Ice::Current&) +#ifdef ICE_CPP11_MAPPING +shared_ptr<Ice::ObjectPrx> +MyDerivedClassI::echo(shared_ptr<Ice::ObjectPrx> obj, const Ice::Current&) +{ + return obj; +} +#else +Ice::ObjectPrx +MyDerivedClassI::echo(const Ice::ObjectPrx& obj, const Ice::Current&) { return obj; } +#endif void MyDerivedClassI::shutdown(const Ice::Current& c) @@ -35,13 +43,18 @@ MyDerivedClassI::getContext(const Ice::Current&) return _ctx; } +#ifdef ICE_CPP11_MAPPING bool -MyDerivedClassI::ice_isA(const std::string& s, const Ice::Current& current) const +MyDerivedClassI::ice_isA(string s, const Ice::Current& current) const { _ctx = current.ctx; -#ifdef ICE_CPP11_MAPPING - return Test::MyDerivedClassDisp::ice_isA(s, current); + return Test::MyDerivedClassDisp::ice_isA(move(s), current); +} #else +bool +MyDerivedClassI::ice_isA(const std::string& s, const Ice::Current& current) const +{ + _ctx = current.ctx; return Test::MyDerivedClass::ice_isA(s, current); -#endif } +#endif
\ No newline at end of file diff --git a/cpp/test/Ice/proxy/TestI.h b/cpp/test/Ice/proxy/TestI.h index f032507e3d8..de45a748e5c 100644 --- a/cpp/test/Ice/proxy/TestI.h +++ b/cpp/test/Ice/proxy/TestI.h @@ -22,11 +22,15 @@ class MyDerivedClassI : public: MyDerivedClassI(); - - virtual Ice::ObjectPrxPtr echo(const Ice::ObjectPrxPtr&, const Ice::Current&); +#ifdef ICE_CPP11_MAPPING + virtual std::shared_ptr<Ice::ObjectPrx> echo(std::shared_ptr<Ice::ObjectPrx>, const Ice::Current&); + virtual bool ice_isA(std::string, const Ice::Current&) const; +#else + virtual Ice::ObjectPrx echo(const Ice::ObjectPrx&, const Ice::Current&); + virtual bool ice_isA(const std::string&, const Ice::Current&) const; +#endif virtual void shutdown(const Ice::Current&); virtual Ice::Context getContext(const Ice::Current&); - virtual bool ice_isA(const std::string&, const Ice::Current&) const; private: diff --git a/cpp/test/Ice/slicing/objects/TestAMDI.cpp b/cpp/test/Ice/slicing/objects/TestAMDI.cpp index c62513909a5..129fd66d9f3 100644 --- a/cpp/test/Ice/slicing/objects/TestAMDI.cpp +++ b/cpp/test/Ice/slicing/objects/TestAMDI.cpp @@ -22,7 +22,7 @@ TestI::TestI() void TestI::SBaseAsObject_async(function<void (const shared_ptr<Ice::Value>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto sb = make_shared<SBase>(); @@ -32,7 +32,7 @@ TestI::SBaseAsObject_async(function<void (const shared_ptr<Ice::Value>&)> respon void TestI::SBaseAsSBase_async(function<void (const shared_ptr<Test::SBase>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto sb = make_shared<SBase>(); @@ -42,7 +42,7 @@ TestI::SBaseAsSBase_async(function<void (const shared_ptr<Test::SBase>&)> respon void TestI::SBSKnownDerivedAsSBase_async(function<void (const shared_ptr<Test::SBase>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto sbskd = make_shared<SBSKnownDerived>(); @@ -53,7 +53,7 @@ TestI::SBSKnownDerivedAsSBase_async(function<void (const shared_ptr<Test::SBase> void TestI::SBSKnownDerivedAsSBSKnownDerived_async(function<void (const shared_ptr<Test::SBSKnownDerived>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto sbskd = make_shared<SBSKnownDerived>(); @@ -65,7 +65,7 @@ TestI::SBSKnownDerivedAsSBSKnownDerived_async(function<void (const shared_ptr<Te void TestI::SBSUnknownDerivedAsSBase_async(function<void (const shared_ptr<Test::SBase>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto sbsud = make_shared<SBSUnknownDerived>(); @@ -74,10 +74,9 @@ TestI::SBSUnknownDerivedAsSBase_async(function<void (const shared_ptr<Test::SBas response(sbsud); } - void TestI::SBSUnknownDerivedAsSBaseCompact_async(function<void (const shared_ptr<Test::SBase>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto sbsud = make_shared<SBSUnknownDerived>(); @@ -89,7 +88,7 @@ TestI::SBSUnknownDerivedAsSBaseCompact_async(function<void (const shared_ptr<Tes void TestI::SUnknownAsObject_async(function<void (const shared_ptr<Ice::Value>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto su = make_shared<SUnknown>(); @@ -98,9 +97,9 @@ TestI::SUnknownAsObject_async(function<void (const shared_ptr<Ice::Value>&)> res } void -TestI::checkSUnknown_async(const Ice::ValuePtr& obj, +TestI::checkSUnknown_async(Ice::ValuePtr obj, function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current& current) { auto su = dynamic_pointer_cast<SUnknown>(obj); @@ -119,7 +118,7 @@ TestI::checkSUnknown_async(const Ice::ValuePtr& obj, void TestI::oneElementCycle_async(function<void (const shared_ptr<Test::B>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto b = make_shared<B>(); @@ -130,7 +129,7 @@ TestI::oneElementCycle_async(function<void (const shared_ptr<Test::B>&)> respons void TestI::twoElementCycle_async(function<void (const shared_ptr<Test::B>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto b1 = make_shared<B>(); @@ -144,7 +143,7 @@ TestI::twoElementCycle_async(function<void (const shared_ptr<Test::B>&)> respons void TestI::D1AsB_async(function<void (const shared_ptr<Test::B>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto d1 = make_shared<D1>(); @@ -163,7 +162,7 @@ TestI::D1AsB_async(function<void (const shared_ptr<Test::B>&)> response, void TestI::D1AsD1_async(function<void (const shared_ptr<Test::D1>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto d1 = make_shared<D1>(); @@ -181,7 +180,7 @@ TestI::D1AsD1_async(function<void (const shared_ptr<Test::D1>&)> response, void TestI::D2AsB_async(function<void (const shared_ptr<Test::B>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto d2 = make_shared<D2>(); @@ -198,8 +197,9 @@ TestI::D2AsB_async(function<void (const shared_ptr<Test::B>&)> response, } void -TestI::paramTest1_async(function<void (const shared_ptr<Test::B>&, const shared_ptr<Test::B>&)> response, - function<void (const exception_ptr&)>, +TestI::paramTest1_async(function<void (const shared_ptr<Test::B>&, + const shared_ptr<Test::B>&)> response, + function<void (exception_ptr)>, const ::Ice::Current&) { auto d1 = make_shared<D1>(); @@ -217,7 +217,7 @@ TestI::paramTest1_async(function<void (const shared_ptr<Test::B>&, const shared_ void TestI::paramTest2_async(function<void (const shared_ptr<Test::B>&, const shared_ptr<Test::B>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto d1 = make_shared<D1>(); @@ -237,7 +237,7 @@ void TestI::paramTest3_async(function<void (const shared_ptr<Test::B>&, const shared_ptr<Test::B>&, const shared_ptr<Test::B>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto d2 = make_shared<D2>(); @@ -270,7 +270,7 @@ TestI::paramTest3_async(function<void (const shared_ptr<Test::B>&, void TestI::paramTest4_async(function<void (const shared_ptr<Test::B>&, const shared_ptr<Test::B>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto d4 = make_shared<D4>(); @@ -287,7 +287,7 @@ void TestI::returnTest1_async(function<void (const shared_ptr<Test::B>&, const shared_ptr<Test::B>&, const shared_ptr<Test::B>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto d1 = make_shared<D1>(); @@ -308,7 +308,7 @@ void TestI::returnTest2_async(function<void (const shared_ptr<Test::B>&, const shared_ptr<Test::B>&, const shared_ptr<Test::B>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto d1 = make_shared<D1>(); @@ -325,9 +325,10 @@ TestI::returnTest2_async(function<void (const shared_ptr<Test::B>&, } void -TestI::returnTest3_async(const ::Test::BPtr& p1, const ::Test::BPtr&, +TestI::returnTest3_async(shared_ptr<::Test::B> p1, + shared_ptr<::Test::B>, function<void (const shared_ptr<Test::B>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { response(p1); @@ -335,23 +336,23 @@ TestI::returnTest3_async(const ::Test::BPtr& p1, const ::Test::BPtr&, void -TestI::sequenceTest_async(const shared_ptr<::Test::SS1>& p1, - const shared_ptr<::Test::SS2>& p2, +TestI::sequenceTest_async(shared_ptr<::Test::SS1> p1, + shared_ptr<::Test::SS2> p2, function<void (const ::Test::SS3&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { SS3 ss; - ss.c1 = p1; - ss.c2 = p2; + ss.c1 = move(p1); + ss.c2 = move(p2); response(ss); } void -TestI::dictionaryTest_async(const Test::BDict& bin, +TestI::dictionaryTest_async(Test::BDict bin, function<void (const ::Test::BDict&, const ::Test::BDict&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { BDict bout; @@ -382,9 +383,9 @@ TestI::dictionaryTest_async(const Test::BDict& bin, } void -TestI::exchangePBase_async(const shared_ptr<::Test::PBase>& pb, +TestI::exchangePBase_async(shared_ptr<::Test::PBase> pb, function<void (const shared_ptr<::Test::PBase>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { response(pb); @@ -393,7 +394,7 @@ TestI::exchangePBase_async(const shared_ptr<::Test::PBase>& pb, void TestI::PBSUnknownAsPreserved_async(function<void (const shared_ptr<::Test::Preserved>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current& current) { auto r = make_shared<PSUnknown>(); @@ -413,9 +414,9 @@ TestI::PBSUnknownAsPreserved_async(function<void (const shared_ptr<::Test::Prese } void -TestI::checkPBSUnknown_async(const shared_ptr<::Test::Preserved>& p, +TestI::checkPBSUnknown_async(shared_ptr<::Test::Preserved> p, function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current& current) { auto pu = dynamic_pointer_cast<PSUnknown>(p); @@ -439,7 +440,7 @@ TestI::checkPBSUnknown_async(const shared_ptr<::Test::Preserved>& p, void TestI::PBSUnknownAsPreservedWithGraph_async(function<void (const shared_ptr<::Test::Preserved>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto r = make_shared<PSUnknown>(); @@ -456,9 +457,9 @@ TestI::PBSUnknownAsPreservedWithGraph_async(function<void (const shared_ptr<::Te void -TestI::checkPBSUnknownWithGraph_async(const ::Test::PreservedPtr& p, +TestI::checkPBSUnknownWithGraph_async(shared_ptr<::Test::Preserved> p, function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current& current) { auto pu = dynamic_pointer_cast<PSUnknown>(p); @@ -484,7 +485,7 @@ TestI::checkPBSUnknownWithGraph_async(const ::Test::PreservedPtr& p, void TestI::PBSUnknown2AsPreservedWithGraph_async(function<void (const shared_ptr<::Test::Preserved>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto r = make_shared<PSUnknown2>(); @@ -496,9 +497,9 @@ TestI::PBSUnknown2AsPreservedWithGraph_async(function<void (const shared_ptr<::T } void -TestI::checkPBSUnknown2WithGraph_async(const shared_ptr<::Test::Preserved>& p, +TestI::checkPBSUnknown2WithGraph_async(shared_ptr<::Test::Preserved> p, function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current& current) { auto pu = dynamic_pointer_cast<PSUnknown2>(p); @@ -520,9 +521,9 @@ TestI::checkPBSUnknown2WithGraph_async(const shared_ptr<::Test::Preserved>& p, } void -TestI::exchangePNode_async(const ::Test::PNodePtr& pn, +TestI::exchangePNode_async(shared_ptr<::Test::PNode> pn, function<void (const shared_ptr<::Test::PNode>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { response(pn); @@ -530,7 +531,7 @@ TestI::exchangePNode_async(const ::Test::PNodePtr& pn, void TestI::throwBaseAsBase_async(function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const ::Ice::Current&) { try @@ -550,7 +551,7 @@ TestI::throwBaseAsBase_async(function<void ()>, void TestI::throwDerivedAsBase_async(function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const ::Ice::Current&) { try @@ -576,7 +577,7 @@ TestI::throwDerivedAsBase_async(function<void ()>, void TestI::throwDerivedAsDerived_async(function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const ::Ice::Current&) { try @@ -602,7 +603,7 @@ TestI::throwDerivedAsDerived_async(function<void ()>, void TestI::throwUnknownDerivedAsBase_async(function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const ::Ice::Current&) { try @@ -628,7 +629,7 @@ TestI::throwUnknownDerivedAsBase_async(function<void ()>, void TestI::throwPreservedException_async(function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const ::Ice::Current&) { try @@ -649,18 +650,18 @@ TestI::throwPreservedException_async(function<void ()>, void TestI::useForward_async(function<void (const shared_ptr<::Test::Forward>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { auto f = make_shared<Forward>(); - f->h = make_shared<Hidden>; + f->h = make_shared<Hidden>(); f->h->f = f; response(f); } void TestI::shutdown_async(function<void ()> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current& current) { current.adapter->getCommunicator()->shutdown(); diff --git a/cpp/test/Ice/slicing/objects/TestAMDI.h b/cpp/test/Ice/slicing/objects/TestAMDI.h index 9248f8d9078..afce6719753 100644 --- a/cpp/test/Ice/slicing/objects/TestAMDI.h +++ b/cpp/test/Ice/slicing/objects/TestAMDI.h @@ -19,169 +19,171 @@ public: TestI(); #ifdef ICE_CPP11_MAPPING virtual void SBaseAsObject_async(std::function<void (const std::shared_ptr<Ice::Value>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void SBaseAsSBase_async(std::function<void (const std::shared_ptr<Test::SBase>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void SBSKnownDerivedAsSBase_async(std::function<void (const std::shared_ptr<Test::SBase>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void SBSKnownDerivedAsSBSKnownDerived_async(std::function<void (const std::shared_ptr<Test::SBSKnownDerived>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void SBSUnknownDerivedAsSBase_async(std::function<void (const std::shared_ptr<Test::SBase>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void SBSUnknownDerivedAsSBaseCompact_async(std::function<void (const std::shared_ptr<Test::SBase>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void SUnknownAsObject_async(std::function<void (const std::shared_ptr<Ice::Value>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); - virtual void checkSUnknown_async(const Ice::ValuePtr&, + virtual void checkSUnknown_async(std::shared_ptr<Ice::Value>, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void oneElementCycle_async(std::function<void (const std::shared_ptr<Test::B>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void twoElementCycle_async(std::function<void (const std::shared_ptr<Test::B>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void D1AsB_async(std::function<void (const std::shared_ptr<Test::B>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void D1AsD1_async(std::function<void (const std::shared_ptr<Test::D1>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void D2AsB_async(std::function<void (const std::shared_ptr<Test::B>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void paramTest1_async(std::function<void (const std::shared_ptr<Test::B>&, const std::shared_ptr<Test::B>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void paramTest2_async(std::function<void (const std::shared_ptr<Test::B>&, const std::shared_ptr<Test::B>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void paramTest3_async(std::function<void (const std::shared_ptr<Test::B>&, const std::shared_ptr<Test::B>&, const std::shared_ptr<Test::B>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void paramTest4_async(std::function<void (const std::shared_ptr<Test::B>&, const std::shared_ptr<Test::B>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void returnTest1_async(std::function<void (const std::shared_ptr<Test::B>&, const std::shared_ptr<Test::B>&, const std::shared_ptr<Test::B>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void returnTest2_async(std::function<void (const std::shared_ptr<Test::B>&, const std::shared_ptr<Test::B>&, const std::shared_ptr<Test::B>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); - virtual void returnTest3_async(const ::Test::BPtr&, const ::Test::BPtr&, + virtual void returnTest3_async(std::shared_ptr<::Test::B>, + std::shared_ptr<::Test::B>, std::function<void (const std::shared_ptr<Test::B>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); - virtual void sequenceTest_async(const ::std::shared_ptr<::Test::SS1>&, - const ::std::shared_ptr<::Test::SS2>&, + virtual void sequenceTest_async(std::shared_ptr<::Test::SS1>, + std::shared_ptr<::Test::SS2>, std::function<void (const ::Test::SS3&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); - virtual void dictionaryTest_async(const Test::BDict&, + virtual void dictionaryTest_async(Test::BDict, std::function<void (const ::Test::BDict&, const ::Test::BDict&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); - virtual void exchangePBase_async(const std::shared_ptr<::Test::PBase>&, + virtual void exchangePBase_async(std::shared_ptr<::Test::PBase>, std::function<void (const std::shared_ptr<::Test::PBase>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void PBSUnknownAsPreserved_async(std::function<void (const std::shared_ptr<::Test::Preserved>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); - virtual void checkPBSUnknown_async(const std::shared_ptr<::Test::Preserved>&, + virtual void checkPBSUnknown_async(std::shared_ptr<::Test::Preserved>, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void PBSUnknownAsPreservedWithGraph_async(std::function<void (const std::shared_ptr<::Test::Preserved>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); - virtual void checkPBSUnknownWithGraph_async(const ::Test::PreservedPtr&, + virtual void checkPBSUnknownWithGraph_async(std::shared_ptr<::Test::Preserved>, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void PBSUnknown2AsPreservedWithGraph_async(std::function<void (const std::shared_ptr<::Test::Preserved>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); - virtual void checkPBSUnknown2WithGraph_async(const std::shared_ptr<::Test::Preserved>&, + virtual void checkPBSUnknown2WithGraph_async(std::shared_ptr<::Test::Preserved>, std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); - virtual void exchangePNode_async(const ::Test::PNodePtr&, + virtual void exchangePNode_async(std::shared_ptr<::Test::PNode>, std::function<void (const std::shared_ptr<::Test::PNode>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void throwBaseAsBase_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void throwDerivedAsBase_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); + virtual void throwDerivedAsDerived_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void throwUnknownDerivedAsBase_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void throwPreservedException_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void useForward_async(std::function<void (const std::shared_ptr<::Test::Forward>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); virtual void shutdown_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); #else virtual void SBaseAsObject_async(const ::Test::AMD_TestIntf_SBaseAsObjectPtr&, const ::Ice::Current&); diff --git a/cpp/test/Ice/slicing/objects/TestI.cpp b/cpp/test/Ice/slicing/objects/TestI.cpp index 65f6bf5fdfb..896928c8eed 100644 --- a/cpp/test/Ice/slicing/objects/TestI.cpp +++ b/cpp/test/Ice/slicing/objects/TestI.cpp @@ -79,7 +79,7 @@ TestI::SUnknownAsObject(const ::Ice::Current&) } void -TestI::checkSUnknown(const Ice::ValuePtr& obj, const ::Ice::Current& current) +TestI::checkSUnknown(ICE_IN(Ice::ValuePtr) obj, const ::Ice::Current& current) { SUnknownPtr su = ICE_DYNAMIC_CAST(SUnknown, obj); if(current.encoding == Ice::Encoding_1_0) @@ -267,13 +267,13 @@ TestI::returnTest2(BPtr& p1, BPtr& p2, const ::Ice::Current&) } BPtr -TestI::returnTest3(const BPtr& p1, const BPtr&, const ::Ice::Current&) +TestI::returnTest3(ICE_IN(BPtr) p1, ICE_IN(BPtr), const ::Ice::Current&) { return p1; } SS3 -TestI::sequenceTest(const SS1Ptr& p1, const SS2Ptr& p2, const ::Ice::Current&) +TestI::sequenceTest(ICE_IN(SS1Ptr) p1, ICE_IN(SS2Ptr) p2, const ::Ice::Current&) { SS3 ss; ss.c1 = p1; @@ -282,7 +282,7 @@ TestI::sequenceTest(const SS1Ptr& p1, const SS2Ptr& p2, const ::Ice::Current&) } Test::BDict -TestI::dictionaryTest(const BDict& bin, BDict& bout, const ::Ice::Current&) +TestI::dictionaryTest(ICE_IN(BDict) bin, BDict& bout, const ::Ice::Current&) { int i; for(i = 0; i < 10; ++i) @@ -317,7 +317,7 @@ TestI::dictionaryTest(const BDict& bin, BDict& bout, const ::Ice::Current&) } Test::PBasePtr -TestI::exchangePBase(const Test::PBasePtr& pb, const Ice::Current&) +TestI::exchangePBase(ICE_IN(Test::PBasePtr) pb, const Ice::Current&) { return pb; } @@ -342,7 +342,7 @@ TestI::PBSUnknownAsPreserved(const Ice::Current& current) } void -TestI::checkPBSUnknown(const Test::PreservedPtr& p, const Ice::Current& current) +TestI::checkPBSUnknown(ICE_IN(Test::PreservedPtr) p, const Ice::Current& current) { PSUnknownPtr pu = ICE_DYNAMIC_CAST(PSUnknown, p); if(current.encoding == Ice::Encoding_1_0) @@ -365,7 +365,7 @@ TestI::checkPBSUnknown(const Test::PreservedPtr& p, const Ice::Current& current) #ifdef ICE_CPP11_MAPPING void TestI::PBSUnknownAsPreservedWithGraph_async(function<void (const shared_ptr<Test::Preserved>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) #else void @@ -390,7 +390,7 @@ TestI::PBSUnknownAsPreservedWithGraph_async(const Test::AMD_TestIntf_PBSUnknownA } void -TestI::checkPBSUnknownWithGraph(const Test::PreservedPtr& p, const Ice::Current& current) +TestI::checkPBSUnknownWithGraph(ICE_IN(Test::PreservedPtr) p, const Ice::Current& current) { PSUnknownPtr pu = ICE_DYNAMIC_CAST(PSUnknown, p); if(current.encoding == Ice::Encoding_1_0) @@ -415,7 +415,7 @@ TestI::checkPBSUnknownWithGraph(const Test::PreservedPtr& p, const Ice::Current& #ifdef ICE_CPP11_MAPPING void TestI::PBSUnknown2AsPreservedWithGraph_async(function<void (const shared_ptr<Test::Preserved>&)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const Ice::Current&) #else void @@ -436,7 +436,7 @@ TestI::PBSUnknown2AsPreservedWithGraph_async(const Test::AMD_TestIntf_PBSUnknown } void -TestI::checkPBSUnknown2WithGraph(const Test::PreservedPtr& p, const Ice::Current& current) +TestI::checkPBSUnknown2WithGraph(ICE_IN(Test::PreservedPtr) p, const Ice::Current& current) { PSUnknown2Ptr pu = ICE_DYNAMIC_CAST(PSUnknown2, p); if(current.encoding == Ice::Encoding_1_0) @@ -456,7 +456,7 @@ TestI::checkPBSUnknown2WithGraph(const Test::PreservedPtr& p, const Ice::Current } Test::PNodePtr -TestI::exchangePNode(const Test::PNodePtr& pn, const Ice::Current&) +TestI::exchangePNode(ICE_IN(Test::PNodePtr) pn, const Ice::Current&) { return pn; } @@ -539,7 +539,7 @@ TestI::throwUnknownDerivedAsBase(const ::Ice::Current&) #ifdef ICE_CPP11_MAPPING void TestI::throwPreservedException_async(function<void ()>, - function<void (const exception_ptr&)> exception, + function<void (exception_ptr)> exception, const ::Ice::Current&) #else void diff --git a/cpp/test/Ice/slicing/objects/TestI.h b/cpp/test/Ice/slicing/objects/TestI.h index f6ffb1b99a5..31c952e0ae2 100644 --- a/cpp/test/Ice/slicing/objects/TestI.h +++ b/cpp/test/Ice/slicing/objects/TestI.h @@ -11,6 +11,7 @@ #define TESTI_H #include <ServerPrivate.h> +#include <TestCommon.h> class TestI : virtual public Test::TestIntf { @@ -28,7 +29,7 @@ public: virtual ::Test::SBasePtr SBSUnknownDerivedAsSBaseCompact(const ::Ice::Current&); virtual ::Ice::ValuePtr SUnknownAsObject(const ::Ice::Current&); - virtual void checkSUnknown(const Ice::ValuePtr& object, const ::Ice::Current&); + virtual void checkSUnknown(ICE_IN(Ice::ValuePtr) object, const ::Ice::Current&); virtual ::Test::BPtr oneElementCycle(const ::Ice::Current&); virtual ::Test::BPtr twoElementCycle(const ::Ice::Current&); @@ -44,38 +45,38 @@ public: virtual ::Test::BPtr returnTest1(::Test::BPtr&, ::Test::BPtr&, const ::Ice::Current&); virtual ::Test::BPtr returnTest2(::Test::BPtr&, ::Test::BPtr&, const ::Ice::Current&); - virtual ::Test::BPtr returnTest3(const ::Test::BPtr&, const ::Test::BPtr&, const ::Ice::Current&); + virtual ::Test::BPtr returnTest3(ICE_IN(::Test::BPtr), ICE_IN(::Test::BPtr), const ::Ice::Current&); - virtual ::Test::SS3 sequenceTest(const ::Test::SS1Ptr&, const ::Test::SS2Ptr&, const ::Ice::Current&); + virtual ::Test::SS3 sequenceTest(ICE_IN(::Test::SS1Ptr), ICE_IN(::Test::SS2Ptr), const ::Ice::Current&); - virtual ::Test::BDict dictionaryTest(const ::Test::BDict&, ::Test::BDict&, const ::Ice::Current&); + virtual ::Test::BDict dictionaryTest(ICE_IN(::Test::BDict), ::Test::BDict&, const ::Ice::Current&); - virtual ::Test::PBasePtr exchangePBase(const ::Test::PBasePtr&, const ::Ice::Current&); + virtual ::Test::PBasePtr exchangePBase(ICE_IN(::Test::PBasePtr), const ::Ice::Current&); virtual ::Test::PreservedPtr PBSUnknownAsPreserved(const ::Ice::Current&); - virtual void checkPBSUnknown(const ::Test::PreservedPtr&, const ::Ice::Current&); + virtual void checkPBSUnknown(ICE_IN(::Test::PreservedPtr), const ::Ice::Current&); #ifdef ICE_CPP11_MAPPING virtual void PBSUnknownAsPreservedWithGraph_async(std::function<void (const std::shared_ptr<Test::Preserved>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); #else virtual void PBSUnknownAsPreservedWithGraph_async(const ::Test::AMD_TestIntf_PBSUnknownAsPreservedWithGraphPtr&, const ::Ice::Current&); #endif - virtual void checkPBSUnknownWithGraph(const ::Test::PreservedPtr&, const ::Ice::Current&); + virtual void checkPBSUnknownWithGraph(ICE_IN(::Test::PreservedPtr), const ::Ice::Current&); #ifdef ICE_CPP11_MAPPING virtual void PBSUnknown2AsPreservedWithGraph_async(std::function<void (const std::shared_ptr<Test::Preserved>&)>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); #else virtual void PBSUnknown2AsPreservedWithGraph_async(const ::Test::AMD_TestIntf_PBSUnknown2AsPreservedWithGraphPtr&, const ::Ice::Current&); #endif - virtual void checkPBSUnknown2WithGraph(const ::Test::PreservedPtr&, const ::Ice::Current&); + virtual void checkPBSUnknown2WithGraph(ICE_IN(::Test::PreservedPtr), const ::Ice::Current&); - virtual ::Test::PNodePtr exchangePNode(const ::Test::PNodePtr&, const ::Ice::Current&); + virtual ::Test::PNodePtr exchangePNode(ICE_IN(::Test::PNodePtr), const ::Ice::Current&); virtual void throwBaseAsBase(const ::Ice::Current&); virtual void throwDerivedAsBase(const ::Ice::Current&); @@ -83,7 +84,7 @@ public: virtual void throwUnknownDerivedAsBase(const ::Ice::Current&); #ifdef ICE_CPP11_MAPPING virtual void throwPreservedException_async(std::function<void ()>, - std::function<void (const std::exception_ptr&)>, + std::function<void (std::exception_ptr)>, const ::Ice::Current&); #else virtual void throwPreservedException_async(const ::Test::AMD_TestIntf_throwPreservedExceptionPtr&, diff --git a/cpp/test/Ice/timeout/TestI.cpp b/cpp/test/Ice/timeout/TestI.cpp index ba41c405bf0..f8bb6af5431 100644 --- a/cpp/test/Ice/timeout/TestI.cpp +++ b/cpp/test/Ice/timeout/TestI.cpp @@ -42,7 +42,7 @@ TimeoutI::op(const Ice::Current&) } void -TimeoutI::sendData(const Test::ByteSeq&, const Ice::Current&) +TimeoutI::sendData(ICE_IN(Test::ByteSeq), const Ice::Current&) { } diff --git a/cpp/test/Ice/timeout/TestI.h b/cpp/test/Ice/timeout/TestI.h index a82a9357691..494d53832ac 100644 --- a/cpp/test/Ice/timeout/TestI.h +++ b/cpp/test/Ice/timeout/TestI.h @@ -11,13 +11,14 @@ #define TEST_I_H #include <Test.h> +#include <TestCommon.h> class TimeoutI : virtual public Test::Timeout { public: virtual void op(const Ice::Current&); - virtual void sendData(const Test::ByteSeq&, const Ice::Current&); + virtual void sendData(ICE_IN(Test::ByteSeq), const Ice::Current&); virtual void sleep(Ice::Int, const Ice::Current&); virtual void holdAdapter(Ice::Int, const Ice::Current&); virtual void shutdown(const Ice::Current&); diff --git a/cpp/test/Ice/udp/TestI.cpp b/cpp/test/Ice/udp/TestI.cpp index 468dba622d0..10224dd8f36 100644 --- a/cpp/test/Ice/udp/TestI.cpp +++ b/cpp/test/Ice/udp/TestI.cpp @@ -15,7 +15,7 @@ using namespace std; using namespace Ice; void -TestIntfI::ping(const Test::PingReplyPrxPtr& reply, const Current&) +TestIntfI::ping(ICE_IN(Test::PingReplyPrxPtr) reply, const Current&) { try { @@ -28,7 +28,7 @@ TestIntfI::ping(const Test::PingReplyPrxPtr& reply, const Current&) } void -TestIntfI::sendByteSeq(const Test::ByteSeq&, const Test::PingReplyPrxPtr& reply, const Current&) +TestIntfI::sendByteSeq(ICE_IN(Test::ByteSeq), ICE_IN(Test::PingReplyPrxPtr) reply, const Current&) { try { @@ -41,7 +41,7 @@ TestIntfI::sendByteSeq(const Test::ByteSeq&, const Test::PingReplyPrxPtr& reply, } void -TestIntfI::pingBiDir(const Ice::Identity& id, const Ice::Current& current) +TestIntfI::pingBiDir(ICE_IN(Ice::Identity) id, const Ice::Current& current) { try { diff --git a/cpp/test/Ice/udp/TestI.h b/cpp/test/Ice/udp/TestI.h index b0f738c98c5..75112c37484 100644 --- a/cpp/test/Ice/udp/TestI.h +++ b/cpp/test/Ice/udp/TestI.h @@ -11,14 +11,15 @@ #define TEST_I_H #include <Test.h> +#include <TestCommon.h> class TestIntfI : public Test::TestIntf { public: - virtual void ping(const Test::PingReplyPrxPtr&, const Ice::Current&); - virtual void sendByteSeq(const Test::ByteSeq&, const Test::PingReplyPrxPtr&, const Ice::Current&); - virtual void pingBiDir(const Ice::Identity&, const Ice::Current&); + virtual void ping(ICE_IN(Test::PingReplyPrxPtr), const Ice::Current&); + virtual void sendByteSeq(ICE_IN(Test::ByteSeq), ICE_IN(Test::PingReplyPrxPtr), const Ice::Current&); + virtual void pingBiDir(ICE_IN(Ice::Identity), const Ice::Current&); virtual void shutdown(const Ice::Current&); }; diff --git a/cpp/test/IceDiscovery/simple/TestI.cpp b/cpp/test/IceDiscovery/simple/TestI.cpp index 66bce832ec9..9ce34f86a75 100644 --- a/cpp/test/IceDiscovery/simple/TestI.cpp +++ b/cpp/test/IceDiscovery/simple/TestI.cpp @@ -21,9 +21,9 @@ TestIntfI::getAdapterId(const Ice::Current& current) } void -ControllerI::activateObjectAdapter(const string& name, - const string& adapterId, - const string& replicaGroupId, +ControllerI::activateObjectAdapter(ICE_IN(string) name, + ICE_IN(string) adapterId, + ICE_IN(string) replicaGroupId, const Ice::Current& current) { Ice::CommunicatorPtr communicator = current.adapter->getCommunicator(); @@ -36,14 +36,14 @@ ControllerI::activateObjectAdapter(const string& name, } void -ControllerI::deactivateObjectAdapter(const string& name, const Ice::Current& current) +ControllerI::deactivateObjectAdapter(ICE_IN(string) name, const Ice::Current& current) { _adapters[name]->destroy(); _adapters.erase(name); } void -ControllerI::addObject(const string& oaName, const string& id, const Ice::Current&) +ControllerI::addObject(ICE_IN(string) oaName, ICE_IN(string) id, const Ice::Current&) { assert(_adapters[oaName]); Ice::Identity identity; @@ -52,7 +52,7 @@ ControllerI::addObject(const string& oaName, const string& id, const Ice::Curren } void -ControllerI::removeObject(const string& oaName, const string& id, const Ice::Current&) +ControllerI::removeObject(ICE_IN(string) oaName, ICE_IN(string) id, const Ice::Current&) { assert(_adapters[oaName]); Ice::Identity identity; diff --git a/cpp/test/IceDiscovery/simple/TestI.h b/cpp/test/IceDiscovery/simple/TestI.h index 9bd608f24fc..7f35e0955c0 100644 --- a/cpp/test/IceDiscovery/simple/TestI.h +++ b/cpp/test/IceDiscovery/simple/TestI.h @@ -11,6 +11,7 @@ #define TEST_I_H #include <Test.h> +#include <TestCommon.h> class TestIntfI : public Test::TestIntf { @@ -23,11 +24,11 @@ class ControllerI : public Test::Controller { public: - virtual void activateObjectAdapter(const std::string&, const std::string&, const std::string&, const Ice::Current&); - virtual void deactivateObjectAdapter(const std::string&, const Ice::Current&); + virtual void activateObjectAdapter(ICE_IN(std::string), ICE_IN(std::string), ICE_IN(std::string), const Ice::Current&); + virtual void deactivateObjectAdapter(ICE_IN(std::string), const Ice::Current&); - virtual void addObject(const std::string&, const std::string&, const Ice::Current&); - virtual void removeObject(const std::string&, const std::string&, const Ice::Current&); + virtual void addObject(ICE_IN(std::string), ICE_IN(std::string), const Ice::Current&); + virtual void removeObject(ICE_IN(std::string), ICE_IN(std::string), const Ice::Current&); virtual void shutdown(const Ice::Current&); diff --git a/cpp/test/Slice/keyword/Client.cpp b/cpp/test/Slice/keyword/Client.cpp index ea833ebce9d..138750fe97d 100644 --- a/cpp/test/Slice/keyword/Client.cpp +++ b/cpp/test/Slice/keyword/Client.cpp @@ -20,7 +20,7 @@ public: #ifdef ICE_CPP11_MAPPING virtual void case_async(::Ice::Int, function<void (int)> response, - function<void (const exception_ptr&)>, + function<void (exception_ptr)>, const ::Ice::Current&) { response(0); @@ -50,7 +50,7 @@ public: class switchI: public _cpp_and::_cpp_switch { public: - virtual void foo(const _cpp_and::charPrx&, Ice::Int&, const ::Ice::Current&) + virtual void foo(_cpp_and::charPrx, Ice::Int&, const ::Ice::Current&) { } }; diff --git a/cpp/test/include/TestCommon.h b/cpp/test/include/TestCommon.h index 37642613bc2..1341dd65f58 100644 --- a/cpp/test/include/TestCommon.h +++ b/cpp/test/include/TestCommon.h @@ -12,6 +12,12 @@ #include <IceUtil/IceUtil.h> +#ifdef ICE_CPP11_MAPPING +# define ICE_IN(T) T +#else +# define ICE_IN(T) const T##& +#endif + #if defined(ICE_OS_WINRT) || (TARGET_OS_IPHONE) # include <Ice/Initialize.h> # include <Ice/Logger.h> |