Logo Search packages:      
Sourcecode: ardour version File versions

sigc::signal< T_return, T_arg1, T_arg2, T_arg3, T_arg4, T_arg5, T_arg6, T_arg7 > Class Template Reference
[Signals]

#include <signal.h>

Inheritance diagram for sigc::signal< T_return, T_arg1, T_arg2, T_arg3, T_arg4, T_arg5, T_arg6, T_arg7 >:

sigc::signal7< T_return, T_arg1, T_arg2, T_arg3, T_arg4, T_arg5, T_arg6, T_arg7, nil_ > sigc::signal_base sigc::trackable

List of all members.


Detailed Description

template<class T_return, class T_arg1 = nil_, class T_arg2 = nil_, class T_arg3 = nil_, class T_arg4 = nil_, class T_arg5 = nil_, class T_arg6 = nil_, class T_arg7 = nil_>
class sigc::signal< T_return, T_arg1, T_arg2, T_arg3, T_arg4, T_arg5, T_arg6, T_arg7 >

Convenience wrapper for the numbered sigc::signal# templates. signal can be used to connect() slots that are invoked during subsequent calls to emit(). Any functor or slot can be passed into connect(). It is converted into a slot implicitly.

If you want to connect one signal to another, use make_slot() to retrieve a functor that emits the signal when invoked.

Be careful if you directly pass one signal into the connect() method of another: a shallow copy of the signal is made and the signal's slots are not disconnected until both the signal and its clone are destroyed which is probably not what you want!

An STL-style list interface for the signal's list of slots can be retrieved with slots(). This interface supports iteration, insertion and removal of slots.

The template arguments determine the function signature of the emit() function:

To specify an accumulator type the nested class signal::accumulated can be used.

Example:
   void foo(int) {}
   sigc::signal<void, long> sig;
   sig.connect(sigc::ptr_fun(&foo));
   sig.emit(19);

Definition at line 2476 of file signal.h.


Public Types

typedef size_t size_type

Public Member Functions

void clear ()
 Empties the list of slots.
bool empty () const
 signal (const signal &src)
size_type size () const

Package Types

typedef
slot_list_type::const_iterator 
const_iterator
typedef
slot_list_type::const_reverse_iterator 
const_reverse_iterator
typedef slot_list_type::iterator iterator
typedef emitter_type::result_type result_type
typedef
slot_list_type::reverse_iterator 
reverse_iterator
typedef slot_list< slot_typeslot_list_type
typedef slot< T_return, T_arg1,
T_arg2, T_arg3, T_arg4, T_arg5,
T_arg6, T_arg7 > 
slot_type

Package Functions

void add_destroy_notify_callback (void *data, func_destroy_notify func) const
iterator_type connect (const slot_base &slot_)
iterator connect (const slot_type &slot_)
result_type emit (typename type_trait< T_arg1 >::take _A_a1, typename type_trait< T_arg2 >::take _A_a2, typename type_trait< T_arg3 >::take _A_a3, typename type_trait< T_arg4 >::take _A_a4, typename type_trait< T_arg5 >::take _A_a5, typename type_trait< T_arg6 >::take _A_a6, typename type_trait< T_arg7 >::take _A_a7) const
iterator_type erase (iterator_type i)
internal::signal_implimpl () const
iterator_type insert (iterator_type i, const slot_base &slot_)
bound_const_mem_functor7
< result_type, signal7,
typename type_trait< T_arg1 >
::take, typename type_trait
< T_arg2 >::take, typename
type_trait< T_arg3 >::take,
typename type_trait< T_arg4 >
::take, typename type_trait
< T_arg5 >::take, typename
type_trait< T_arg6 >::take,
typename type_trait< T_arg7 >
::take > 
make_slot () const
void notify_callbacks ()
 Execute and remove all previously installed callbacks.
result_type operator() (typename type_trait< T_arg1 >::take _A_a1, typename type_trait< T_arg2 >::take _A_a2, typename type_trait< T_arg3 >::take _A_a3, typename type_trait< T_arg4 >::take _A_a4, typename type_trait< T_arg5 >::take _A_a5, typename type_trait< T_arg6 >::take _A_a6, typename type_trait< T_arg7 >::take _A_a7) const
void remove_destroy_notify_callback (void *data) const
const slot_list_type slots () const
slot_list_type slots ()

Package Attributes

 __pad0__
nil_ emitter_type
internal::signal_implimpl_
 The signal_impl object encapsulating the slot list.
 T_arg1
 T_arg2
 T_arg3
 T_arg4
 T_arg5
 T_arg6
 T_arg7

Classes

class  accumulated

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

Generated by  Doxygen 1.6.0   Back to index