sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 > Class Template Reference
[Signals]

A threadsafe wrapper for any sigc signal with 5 argument(s). More...

#include <signal_wrapper.h>

Inheritance diagram for sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >:

sigx::signal_wrapper_base sigx::nonheapallocatable

Public Member Functions

 signal_wrapper ()
 Constructs an empty signal_wrapper.
 signal_wrapper (const shared_dispatchable &_A_disp, const std::tr1::shared_ptr< signal_source_base > &_A_sigsource) throw ()
 Creates a signal_wrapper from a signal source.
template<typename T_functor >
connection_wrapper connect (const T_functor &_A_func) const
 Connects a functor, tunnels it automatically if not yet tunneled and activates validity tracking for sigc::trackableS.
template<sync_type I_sync>
result_type emit (arg1_type_ _A_a1, arg2_type_ _A_a2, arg3_type_ _A_a3, arg4_type_ _A_a4, arg5_type_ _A_a5) const
 emits the signal on the other side of the tunnel.
result_type emit (arg1_type_ _A_a1, arg2_type_ _A_a2, arg3_type_ _A_a3, arg4_type_ _A_a4, arg5_type_ _A_a5) const
 emits the signal asynchronously.
result_type emit_sync (arg1_type_ _A_a1, arg2_type_ _A_a2, arg3_type_ _A_a3, arg4_type_ _A_a4, arg5_type_ _A_a5) const
 emits the signal synchronously.
result_type operator() (arg1_type_ _A_a1, arg2_type_ _A_a2, arg3_type_ _A_a3, arg4_type_ _A_a4, arg5_type_ _A_a5) const
template<sync_type I_sync>
tunnel_functor< I_sync,
make_slot_functor_type > 
make_slot () const
 creates a tunnel_functor that emits the signal when invoked
tunnel_functor< ASYNC,
make_slot_functor_type > 
make_slot () const
 creates an asynchronous tunnel_functor that emits the signal when invoked
tunnel_functor< SYNC,
make_slot_functor_type > 
make_slot_sync () const
 creates a synchronous tunnel_functor that emits the signal when invoked

Static Public Attributes

static const int argument_count = 5

Protected Types

typedef
sigc::bound_const_mem_functor0
< signal_source_base::hook,
signal_source_base
make_slot_f1
typedef
sigc::retype_return_functor
< fp_sig_getter_type,
make_slot_f1
make_slot_f2
typedef
sigc::const_mem_functor0
< signal_source_ptr,
std::tr1::shared_ptr
< signal_source_base > > 
make_slot_f3
typedef sigc::bind_functor
<-1, make_slot_f3,
std::tr1::shared_ptr
< signal_source_base > > 
make_slot_f4
typedef sigc::compose1_functor
< make_slot_f2, make_slot_f4
make_slot_composed1_functor_type
typedef
sigc::const_mem_functor5
< result_type, signal_type,
arg1_type_, arg2_type_,
arg3_type_, arg4_type_,
arg5_type_
make_slot_emit_functor_type
typedef sigc::compose1_functor
< make_slot_emit_functor_type,
make_slot_composed1_functor_type
make_slot_composed2_functor_type

Protected Member Functions

typedef SIGX_DISPATCH_WITH_FUNCTOR (make_slot_composed2_functor_type) make_slot_functor_type

Package Types

typedef T_signal signal_type
typedef signal_wrapper
< signal_type, signal_group,
argument_count
this_type
typedef signal_type::slot_type slot_type
typedef signal_type::result_type result_type
typedef slot_type::arg1_type_ arg1_type_
typedef slot_type::arg2_type_ arg2_type_
typedef slot_type::arg3_type_ arg3_type_
typedef slot_type::arg4_type_ arg4_type_
typedef slot_type::arg5_type_ arg5_type_
typedef signal_type(* fp_sig_getter_type )(signal_source_ptr)

Static Package Attributes

 __pad0__:signal_group signal_group = internal::SIGGROUP_SIGC

Detailed Description

template<typename T_signal>
class sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >

A threadsafe wrapper for any sigc signal with 5 argument(s).

Member Typedef Documentation

template<typename T_signal >
typedef slot_type::arg1_type_ sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::arg1_type_ [package]

template<typename T_signal >
typedef slot_type::arg2_type_ sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::arg2_type_ [package]

template<typename T_signal >
typedef slot_type::arg3_type_ sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::arg3_type_ [package]

template<typename T_signal >
typedef slot_type::arg4_type_ sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::arg4_type_ [package]

template<typename T_signal >
typedef slot_type::arg5_type_ sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::arg5_type_ [package]

template<typename T_signal >
typedef signal_type(* sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::fp_sig_getter_type)(signal_source_ptr) [package]

template<typename T_signal >
typedef sigc::compose1_functor<make_slot_f2, make_slot_f4> sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::make_slot_composed1_functor_type [protected]

template<typename T_signal >
typedef sigc::compose1_functor<make_slot_emit_functor_type, make_slot_composed1_functor_type> sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::make_slot_composed2_functor_type [protected]

template<typename T_signal >
typedef sigc::const_mem_functor5<result_type, signal_type, arg1_type_, arg2_type_, arg3_type_, arg4_type_, arg5_type_> sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::make_slot_emit_functor_type [protected]

template<typename T_signal >
typedef sigc::bound_const_mem_functor0<signal_source_base::hook, signal_source_base> sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::make_slot_f1 [protected]

template<typename T_signal >
typedef sigc::retype_return_functor<fp_sig_getter_type, make_slot_f1> sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::make_slot_f2 [protected]

template<typename T_signal >
typedef sigc::const_mem_functor0<signal_source_ptr, std::tr1::shared_ptr<signal_source_base> > sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::make_slot_f3 [protected]

template<typename T_signal >
typedef sigc::bind_functor<-1, make_slot_f3, std::tr1::shared_ptr<signal_source_base> > sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::make_slot_f4 [protected]

template<typename T_signal >
typedef signal_type::result_type sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::result_type [package]

template<typename T_signal >
typedef T_signal sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::signal_type [package]

template<typename T_signal >
typedef signal_type::slot_type sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::slot_type [package]

template<typename T_signal >
typedef signal_wrapper<signal_type, signal_group, argument_count> sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::this_type [package]


Constructor & Destructor Documentation

template<typename T_signal >
sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::signal_wrapper (  )  [inline]

Constructs an empty signal_wrapper.

Exceptions:
Might throw a std::bad_alloc exception (from dispatchable's ctor)

template<typename T_signal >
sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::signal_wrapper ( const shared_dispatchable _A_disp,
const std::tr1::shared_ptr< signal_source_base > &  _A_sigsource 
) throw () [inline]

Creates a signal_wrapper from a signal source.

Parameters:
_A_disp The dispatchable to operate on
_A_sigsource A shared pointer to the server thread's signal source.


Member Function Documentation

template<typename T_signal >
template<typename T_functor >
connection_wrapper sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::connect ( const T_functor &  _A_func  )  const [inline]

Connects a functor, tunnels it automatically if not yet tunneled and activates validity tracking for sigc::trackableS.

auto tunneling is successful only if the passed in functor is a "dispatchable" functor, i.e. a functor on a dispatchable's method or one explicitly created with "dispatch_with". You will get compiler errors if the dispatchable can't be deduced from the passed in functor.

Note:
At the moment it is only possible to pass in a non-tunneled functor or a toplevel tunneled functor due to the fact that the visit_each mechanism is turned off for the tunnel functor (otherwise there would be the problem of not threadsafe access to the sigc::trackable base of the of a dispatchable object..

passed in functor must not be a slot or adapt a slot; we have to apply this restriction because slots might have bound trackables that can cause non-threadsafe access to the passed in slot which will live in the context of the server thread.

Attention:
All sigc::trackableS and the original dispatchable contained in the passed functor must belong to the context of the calling thread.
Returns:
sigx::connection_wrapper A threadsafe connection wrapper
Note:
asynchronous

References sigx::signal_wrapper_base::connect().

template<typename T_signal >
result_type sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::emit ( arg1_type_  _A_a1,
arg2_type_  _A_a2,
arg3_type_  _A_a3,
arg4_type_  _A_a4,
arg5_type_  _A_a5 
) const [inline]

emits the signal asynchronously.

template<typename T_signal >
template<sync_type I_sync>
result_type sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::emit ( arg1_type_  _A_a1,
arg2_type_  _A_a2,
arg3_type_  _A_a3,
arg4_type_  _A_a4,
arg5_type_  _A_a5 
) const [inline]

emits the signal on the other side of the tunnel.

References sigx::signal_source_base::getter().

template<typename T_signal >
result_type sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::emit_sync ( arg1_type_  _A_a1,
arg2_type_  _A_a2,
arg3_type_  _A_a3,
arg4_type_  _A_a4,
arg5_type_  _A_a5 
) const [inline]

emits the signal synchronously.

template<typename T_signal >
tunnel_functor<ASYNC, make_slot_functor_type> sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::make_slot (  )  const [inline]

creates an asynchronous tunnel_functor that emits the signal when invoked

template<typename T_signal >
template<sync_type I_sync>
tunnel_functor<I_sync, make_slot_functor_type> sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::make_slot (  )  const [inline]

creates a tunnel_functor that emits the signal when invoked

References sigx::dispatch_with(), and sigx::signal_source_base::getter().

template<typename T_signal >
tunnel_functor<SYNC, make_slot_functor_type> sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::make_slot_sync (  )  const [inline]

creates a synchronous tunnel_functor that emits the signal when invoked

template<typename T_signal >
result_type sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::operator() ( arg1_type_  _A_a1,
arg2_type_  _A_a2,
arg3_type_  _A_a3,
arg4_type_  _A_a4,
arg5_type_  _A_a5 
) const [inline]

see emit(arg1_type_, arg2_type_, arg3_type_, arg4_type_, arg5_type_)

template<typename T_signal >
typedef sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::SIGX_DISPATCH_WITH_FUNCTOR ( make_slot_composed2_functor_type   )  [protected]


Field Documentation

template<typename T_signal >
sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::__pad0__ [static, package]

template<typename T_signal >
const int sigx::signal_wrapper< T_signal, internal::SIGGROUP_SIGC, 5 >::argument_count = 5 [static]


The documentation for this class was generated from the following file:

Generated on Sun May 17 15:47:35 2009 for sigx++ by  doxygen 1.5.9