Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members

scim::Signal0< R, Marshal > Class Template Reference
[SignalSlotSignalSlot]

A template for a signal passing no arguments and returning a value of type R. More...

#include <scim_signals.h>

Inheritance diagram for scim::Signal0< R, Marshal >:

Inheritance graph
[legend]
Collaboration diagram for scim::Signal0< R, Marshal >:

Collaboration graph
[legend]
List of all members.

Public Types

typedef Slot0< R > SlotType
 Function signature for handlers connecting the signal.

Public Member Functions

Connection connect (SlotType *slot)
SlotTypeslot ()
emit ()
operator() ()
 Function operator; calls emit().

Detailed Description

template<typename R, typename Marshal = class DefaultMarshal<R>>
class scim::Signal0< R, Marshal >

A template for a signal passing no arguments and returning a value of type R.

Definition at line 136 of file scim_signals.h.


Member Typedef Documentation

template<typename R, typename Marshal = class DefaultMarshal<R>>
typedef Slot0<R> scim::Signal0< R, Marshal >::SlotType
 

Function signature for handlers connecting the signal.

Definition at line 148 of file scim_signals.h.

Referenced by scim::Signal0< R, Marshal >::connect(), scim::Signal0< R, Marshal >::emit(), and scim::Signal0< R, Marshal >::slot().


Member Function Documentation

template<typename R, typename Marshal = class DefaultMarshal<R>>
Connection scim::Signal0< R, Marshal >::connect SlotType slot  )  [inline]
 

Connect a slot to the signal. <

Parameters:
slot - a slot of type Slot0<R>. <
Returns:
a connection object. < <
The returned connection object can be used alter or change the connection.
Definition at line 150 of file scim_signals.h.

References scim::slot(), and scim::Signal0< R, Marshal >::SlotType.

template<typename R, typename Marshal = class DefaultMarshal<R>>
SlotType* scim::Signal0< R, Marshal >::slot  )  [inline]
 

Returns a slot for this signal. <

Returns:
a new slot of type Slot0<R>. < <
The returned slot can be passed to another signal allowing the < other signal to call this signal when it gets emitted.
Definition at line 160 of file scim_signals.h.

References scim::Signal0< R, Marshal >::SlotType.

Referenced by scim::Signal0< R, Marshal >::emit().

template<typename R, typename Marshal = class DefaultMarshal<R>>
R scim::Signal0< R, Marshal >::emit  )  [inline]
 

Emit the signal. <

Returns:
the value returned by the signal handler. < <
Calls every slot connected to this signal, in order of connection.
Definition at line 170 of file scim_signals.h.

References scim::slot(), scim::Signal0< R, Marshal >::slot(), and scim::Signal0< R, Marshal >::SlotType.

Referenced by scim::Signal0< void, IgnoreMarshal >::operator()(), and scim::Signal0< R, Marshal >::operator()().

template<typename R, typename Marshal = class DefaultMarshal<R>>
R scim::Signal0< R, Marshal >::operator()  )  [inline]
 

Function operator; calls emit().

Definition at line 191 of file scim_signals.h.

References scim::Signal0< R, Marshal >::emit().


The documentation for this class was generated from the following file:
Generated on Thu Dec 30 21:03:24 2004 for scim by doxygen 1.3.8