16 #ifndef __IceGrid_UserAccountMapper_h__
17 #define __IceGrid_UserAccountMapper_h__
39 #ifndef ICE_IGNORE_VERSION
40 # if ICE_INT_VERSION / 100 != 307
41 # error Ice version mismatch!
43 # if ICE_INT_VERSION % 100 >= 50
44 # error Beta header file detected
46 # if ICE_INT_VERSION % 100 < 10
47 # error Ice patch level mismatch!
52 # if defined(ICE_STATIC_LIBS)
54 # elif defined(ICEGRID_API_EXPORTS)
55 # define ICEGRID_API ICE_DECLSPEC_EXPORT
57 # define ICEGRID_API ICE_DECLSPEC_IMPORT
61 #ifdef ICE_CPP11_MAPPING // C++11 mapping
66 class UserAccountMapper;
79 class ICE_CLASS(ICEGRID_API) UserAccountNotFoundException :
public ::Ice::UserExceptionHelper<UserAccountNotFoundException, ::Ice::UserException>
85 UserAccountNotFoundException(
const UserAccountNotFoundException&) =
default;
87 UserAccountNotFoundException() =
default;
93 std::tuple<> ice_tuple()
const
106 static UserAccountNotFoundException _iceS_UserAccountNotFoundException_init;
131 virtual bool ice_isA(::std::string
id, const ::Ice::Current& current)
const override;
138 virtual ::std::vector<::std::string> ice_ids(const ::Ice::Current& current)
const override;
145 virtual ::std::string ice_id(const ::Ice::Current& current)
const override;
151 static const ::std::string& ice_staticId();
166 virtual ::std::string getUserAccount(::std::string user, const ::Ice::Current& current) = 0;
168 bool _iceD_getUserAccount(::IceInternal::Incoming&, const ::Ice::Current&);
172 virtual bool _iceDispatch(::IceInternal::Incoming&, const ::Ice::Current&)
override;
205 return _makePromiseOutgoing<::std::string>(
true,
this, &UserAccountMapperPrx::_iceI_getUserAccount, user, context).get();
219 template<
template<
typename>
class P = ::std::promise>
221 -> decltype(::std::declval<P<::std::string>>().get_future())
223 return _makePromiseOutgoing<::std::string, P>(
false,
this, &UserAccountMapperPrx::_iceI_getUserAccount, user, context);
240 ::std::function<void()>
241 getUserAccountAsync(const ::std::string& user,
242 ::std::function<
void(::std::string)> response,
243 ::std::function<
void(::std::exception_ptr)> ex =
nullptr,
244 ::std::function<
void(
bool)> sent =
nullptr,
247 return _makeLamdaOutgoing<::std::string>(std::move(response), std::move(ex), std::move(sent),
this, &IceGrid::UserAccountMapperPrx::_iceI_getUserAccount, user, context);
264 friend ::std::shared_ptr<UserAccountMapperPrx> IceInternal::createProxy<UserAccountMapperPrx>();
289 #else // C++98 mapping
297 class UserAccountMapper;
300 ICEGRID_API ::IceProxy::Ice::Object*
upCast(UserAccountMapper*);
310 class UserAccountMapper;
312 ICEGRID_API ::Ice::Object*
upCast(UserAccountMapper*);
337 #ifdef ICE_CPP11_COMPILER
411 return end_getUserAccount(_iceI_begin_getUserAccount(user, context, ::IceInternal::dummyCallback, 0,
true));
427 return _iceI_begin_getUserAccount(user, context, ::IceInternal::dummyCallback, 0);
462 return _iceI_begin_getUserAccount(user, context, cb, cookie);
497 return _iceI_begin_getUserAccount(user, context, cb, cookie);
549 #ifdef ICE_CPP11_COMPILER
598 bool _iceD_getUserAccount(::IceInternal::Incoming&, const ::Ice::Current&);
602 virtual bool _iceDispatch(::IceInternal::Incoming&, const ::Ice::Current&);
619 inline bool operator<(
const UserAccountMapper& lhs,
const UserAccountMapper& rhs)
634 static const StreamHelperCategory helper = StreamHelperCategoryUserException;
656 typedef void (T::*Sent)(bool);
657 typedef void (T::*Response)(const ::std::string&);
660 : ::IceInternal::TwowayCallbackNC<T>(obj, cb != 0, excb, sentcb), _response(cb)
671 ret = proxy->end_getUserAccount(result);
675 ::IceInternal::CallbackNC<T>::exception(result, ex);
680 (::IceInternal::CallbackNC<T>::_callback.get()->*_response)(ret);
723 template<
class T,
typename CT>
731 typedef void (T::*Sent)(bool ,
const CT&);
732 typedef void (T::*Response)(const ::std::string&,
const CT&);
735 : ::IceInternal::TwowayCallback<T, CT>(obj, cb != 0, excb, sentcb), _response(cb)
746 ret = proxy->end_getUserAccount(result);
750 ::IceInternal::Callback<T, CT>::exception(result, ex);
755 (::IceInternal::Callback<T, CT>::_callback.get()->*_response)(ret, CT::dynamicCast(result->getCookie()));