12 #ifndef CREATE_GUARD_FUNCTION_ACA9A120_8AEC_43B3_8745_DDC573C43D63 13 #define CREATE_GUARD_FUNCTION_ACA9A120_8AEC_43B3_8745_DDC573C43D63 20 #ifndef SX_CPP03_BOOST // C++11 22 #ifdef SX_GCC_EXPAND_TEMPLATE_PARAM_PACK_BUG 29 template<
typename function1 >
36 template<
typename function1,
typename function2 >
43 template<
typename function1,
typename function2,
typename function3 >
50 template<
typename function1,
typename function2,
typename function3,
typename function4 >
57 template<
typename function1,
typename function2,
typename function3,
typename function4,
typename function5 >
60 return (
sxy::constraint_function( [_function1, _function2, _function3, _function4, _function5](
const sxy::event& _event,
sxy::event_collector& _event_collector ) {
return(
guard_caller( _event, _event_collector, _function1, _function2, _function3, _function4, _function5 ) ); } ) );
64 template<
typename function1,
typename function2,
typename function3,
typename function4,
typename function5,
typename function6 >
65 sxy::constraint_function create_guard_function(
const function1& _function1,
const function2& _function2,
const function3& _function3,
const function4& _function4,
const function5& _function5,
const function6& _function6 )
67 return (
sxy::constraint_function( [_function1, _function2, _function3, _function4, _function5, _function6](
const sxy::event& _event,
sxy::event_collector& _event_collector ) {
return(
guard_caller( _event, _event_collector, _function1, _function2, _function3, _function4, _function5, _function6 ) ); } ) );
71 template<
typename function1,
typename function2,
typename function3,
typename function4,
typename function5,
typename function6,
typename function7 >
72 sxy::constraint_function create_guard_function(
const function1& _function1,
const function2& _function2,
const function3& _function3,
const function4& _function4,
const function5& _function5,
const function6& _function6,
const function7& _function7 )
74 return (
sxy::constraint_function( [_function1, _function2, _function3, _function4, _function5, _function6, _function7](
const sxy::event& _event,
sxy::event_collector& _event_collector ) {
return(
guard_caller( _event, _event_collector, _function1, _function2, _function3, _function4, _function5, _function6, _function7 ) ); } ) );
78 template<
typename function1,
typename function2,
typename function3,
typename function4,
typename function5,
typename function6,
typename function7,
typename function8 >
79 sxy::constraint_function create_guard_function(
const function1& _function1,
const function2& _function2,
const function3& _function3,
const function4& _function4,
const function5& _function5,
const function6& _function6,
const function7& _function7,
const function8& _function8 )
81 return (
sxy::constraint_function( [_function1, _function2, _function3, _function4, _function5, _function6, _function7, _function8](
const sxy::event& _event,
sxy::event_collector& _event_collector ) {
return(
guard_caller( _event, _event_collector, _function1, _function2, _function3, _function4, _function5, _function6, _function7, _function8 ) ); } ) );
85 template<
typename function1,
typename function2,
typename function3,
typename function4,
typename function5,
typename function6,
typename function7,
typename function8,
typename function9 >
86 sxy::constraint_function create_guard_function(
const function1& _function1,
const function2& _function2,
const function3& _function3,
const function4& _function4,
const function5& _function5,
const function6& _function6,
const function7& _function7,
const function8& _function8,
const function9& _function9 )
88 return (
sxy::constraint_function( [_function1, _function2, _function3, _function4, _function5, _function6, _function7, _function8, _function9](
const sxy::event& _event,
sxy::event_collector& _event_collector ) {
return(
guard_caller( _event, _event_collector, _function1, _function2, _function3, _function4, _function5, _function6, _function7, _function8, _function9 ) ); } ) );
92 template<
typename function1,
typename function2,
typename function3,
typename function4,
typename function5,
typename function6,
typename function7,
typename function8,
typename function9,
typename function10 >
93 sxy::constraint_function create_guard_function(
const function1& _function1,
const function2& _function2,
const function3& _function3,
const function4& _function4,
const function5& _function5,
const function6& _function6,
const function7& _function7,
const function8& _function8,
const function9& _function9, function10 _function10 )
95 return (
sxy::constraint_function( [_function1, _function2, _function3, _function4, _function5, _function6, _function7, _function8, _function9, _function10](
const sxy::event& _event,
sxy::event_collector& _event_collector ) {
return(
guard_caller( _event, _event_collector, _function1, _function2, _function3, _function4, _function5, _function6, _function7, _function8, _function9, _function10 ) ); } ) );
101 #else // !SX_GCC_EXPAND_TEMPLATE_PARAM_PACK_BUG 107 template<
typename ... Args >
117 #endif // SX_GCC_EXPAND_TEMPLATE_PARAM_PACK_BUG 120 #else // C++03 with Boost 133 template<
typename _event_type >
141 template<
typename _event_type1 >
147 const sxe::function<bool( const _event_type1&, sxy::event_collector& )>&
153 template<
typename _event_type1,
typename _event_type2 >
160 const sxe::function<bool( const _event_type1&, sxy::event_collector& )>&,
161 const sxe::function<bool( const _event_type2&, sxy::event_collector& )>&
167 template<
typename _event_type1,
typename _event_type2,
typename _event_type3 >
175 const sxe::function<bool( const _event_type1&, sxy::event_collector& )>&,
176 const sxe::function<bool( const _event_type2&, sxy::event_collector& )>&,
177 const sxe::function<bool( const _event_type3&, sxy::event_collector& )>&
183 template<
typename _event_type1,
typename _event_type2,
typename _event_type3,
typename _event_type4 >
192 const sxe::function<bool( const _event_type1&, sxy::event_collector& )>&,
193 const sxe::function<bool( const _event_type2&, sxy::event_collector& )>&,
194 const sxe::function<bool( const _event_type3&, sxy::event_collector& )>&,
195 const sxe::function<bool( const _event_type4&, sxy::event_collector& )>&
201 template<
typename _event_type1,
typename _event_type2,
typename _event_type3,
typename _event_type4,
typename _event_type5 >
211 const sxe::function<bool( const _event_type1&, sxy::event_collector& )>&,
212 const sxe::function<bool( const _event_type2&, sxy::event_collector& )>&,
213 const sxe::function<bool( const _event_type3&, sxy::event_collector& )>&,
214 const sxe::function<bool( const _event_type4&, sxy::event_collector& )>&,
215 const sxe::function<bool( const _event_type5&, sxy::event_collector& )>&
217 return(
sxy::constraint_function( sxe::bind( static_cast< guard_caller_selector >(
guard_caller ), sxe::_1, sxe::_2, _function1, _function2, _function3, _function4, _function5 ) ) );
221 template<
typename _event_type1,
typename _event_type2,
typename _event_type3,
typename _event_type4,
typename _event_type5,
typename _event_type6 >
232 const sxe::function<bool( const _event_type1&, sxy::event_collector& )>&,
233 const sxe::function<bool( const _event_type2&, sxy::event_collector& )>&,
234 const sxe::function<bool( const _event_type3&, sxy::event_collector& )>&,
235 const sxe::function<bool( const _event_type4&, sxy::event_collector& )>&,
236 const sxe::function<bool( const _event_type5&, sxy::event_collector& )>&,
237 const sxe::function<bool( const _event_type6&, sxy::event_collector& )>&
239 return(
sxy::constraint_function( sxe::bind( static_cast< guard_caller_selector >(
guard_caller ), sxe::_1, sxe::_2, _function1, _function2, _function3, _function4, _function5, _function6 ) ) );
243 template<
typename _event_type1,
typename _event_type2,
typename _event_type3,
typename _event_type4,
typename _event_type5,
typename _event_type6,
typename _event_type7 >
255 const sxe::function<bool( const _event_type1&, sxy::event_collector& )>&,
256 const sxe::function<bool( const _event_type2&, sxy::event_collector& )>&,
257 const sxe::function<bool( const _event_type3&, sxy::event_collector& )>&,
258 const sxe::function<bool( const _event_type4&, sxy::event_collector& )>&,
259 const sxe::function<bool( const _event_type5&, sxy::event_collector& )>&,
260 const sxe::function<bool( const _event_type6&, sxy::event_collector& )>&,
261 const sxe::function<bool( const _event_type7&, sxy::event_collector& )>&
263 return(
sxy::constraint_function( sxe::bind( static_cast< guard_caller_selector >(
guard_caller ), sxe::_1, sxe::_2, _function1, _function2, _function3, _function4, _function5, _function6, _function7 ) ) );
267 template<
typename _event_type1,
typename _event_type2,
typename _event_type3,
typename _event_type4,
typename _event_type5,
typename _event_type6,
typename _event_type7,
typename _event_type8 >
280 const sxe::function<bool( const _event_type1&, sxy::event_collector& )>&,
281 const sxe::function<bool( const _event_type2&, sxy::event_collector& )>&,
282 const sxe::function<bool( const _event_type3&, sxy::event_collector& )>&,
283 const sxe::function<bool( const _event_type4&, sxy::event_collector& )>&,
284 const sxe::function<bool( const _event_type5&, sxy::event_collector& )>&,
285 const sxe::function<bool( const _event_type6&, sxy::event_collector& )>&,
286 const sxe::function<bool( const _event_type7&, sxy::event_collector& )>&,
287 const sxe::function<bool( const _event_type8&, sxy::event_collector& )>&
289 return(
sxy::constraint_function( sxe::bind( static_cast< guard_caller_selector >(
guard_caller ), sxe::_1, sxe::_2, _function1, _function2, _function3, _function4, _function5, _function6, _function7, _function8 ) ) );
293 template<
typename _event_type1,
typename _event_type2,
typename _event_type3,
typename _event_type4,
typename _event_type5,
typename _event_type6,
typename _event_type7,
typename _event_type8,
typename _event_type9 >
307 const sxe::function<bool( const _event_type1&, sxy::event_collector& )>&,
308 const sxe::function<bool( const _event_type2&, sxy::event_collector& )>&,
309 const sxe::function<bool( const _event_type3&, sxy::event_collector& )>&,
310 const sxe::function<bool( const _event_type4&, sxy::event_collector& )>&,
311 const sxe::function<bool( const _event_type5&, sxy::event_collector& )>&,
312 const sxe::function<bool( const _event_type6&, sxy::event_collector& )>&,
313 const sxe::function<bool( const _event_type7&, sxy::event_collector& )>&,
314 const sxe::function<bool( const _event_type8&, sxy::event_collector& )>&,
315 const sxe::function<bool( const _event_type9&, sxy::event_collector& )>&
317 return(
sxy::constraint_function( sxe::bind( static_cast< guard_caller_selector >(
guard_caller ), sxe::_1, sxe::_2, _function1, _function2, _function3, _function4, _function5, _function6, _function7, _function8, _function9 ) ) );
321 template<
typename _event_type1,
typename _event_type2,
typename _event_type3,
typename _event_type4,
typename _event_type5,
typename _event_type6,
typename _event_type7,
typename _event_type8,
typename _event_type9,
typename _event_type10 >
336 const sxe::function<bool( const _event_type1&, sxy::event_collector& )>&,
337 const sxe::function<bool( const _event_type2&, sxy::event_collector& )>&,
338 const sxe::function<bool( const _event_type3&, sxy::event_collector& )>&,
339 const sxe::function<bool( const _event_type4&, sxy::event_collector& )>&,
340 const sxe::function<bool( const _event_type5&, sxy::event_collector& )>&,
341 const sxe::function<bool( const _event_type6&, sxy::event_collector& )>&,
342 const sxe::function<bool( const _event_type7&, sxy::event_collector& )>&,
343 const sxe::function<bool( const _event_type8&, sxy::event_collector& )>&,
344 const sxe::function<bool( const _event_type9&, sxy::event_collector& )>&,
345 const sxe::function<bool( const _event_type10&, sxy::event_collector& )>&
347 return(
sxy::constraint_function( sxe::bind( static_cast< guard_caller_selector >(
guard_caller ), sxe::_1, sxe::_2, _function1, _function2, _function3, _function4, _function5, _function6, _function7, _function8, _function9, _function10 ) ) );
352 #endif // !SX_CPP03_BOOST Definition: event_collector.hpp:25
Interface of an event. An event has an ID, a name and a priority (for processing by the async state m...
Definition: event.hpp:28
Definition: adapter_cpp11.hpp:21
sxy::constraint_function create_guard_function(Args...args)
Definition: create_guard_function.hpp:108
bool guard_caller(const sxy::event &_event, sxy::event_collector &_event_collector, const sxe::function< bool()> &_function)
Definition: guard_caller.cpp:18
sxe::function< bool(const event &, event_collector &) > constraint_function
Definition: constraint_fwd.hpp:28