SignalMultiplier Class Reference

Forwards an event to many slots. More...

#include <basicobject.h>

Inheritance diagram for SignalMultiplier:

Inheritance graph
[legend]
Collaboration diagram for SignalMultiplier:

Collaboration graph
[legend]
List of all members.

Public Member Functions

DECLSPEC SignalMultiplier (const char *name, BasicObject *parent)
DECLSPEC SignalMultiplier (TiXmlElement *el, BasicObject *parent)
DECLSPEC void addSlot (Callback func, BasicObject *aim)
DECLSPEC void removeSlot (Callback func, BasicObject *aim)

Static Public Member Functions

static void event (void *sender, BasicObject *aim, void *data)

Protected Member Functions

DECLSPEC void onInit ()

Detailed Description

Forwards an event to many slots.

This class is designed to be able to send an event to more than just one slot. To do so, create a SignalMultiplier object and connect its "event" slot with a signal. Furthermore you have to add slots that should recieve the event with addSlot().

Test:
whole class


Constructor & Destructor Documentation

SignalMultiplier::SignalMultiplier ( TiXmlElement el,
BasicObject parent 
)

Construction, using XML-data. The XML element must have children, called "Slot", with each having an attribute "Aim".


Member Function Documentation

void SignalMultiplier::onInit (  )  [protected, virtual]

Initializes the object's variables by reading data from the XML element. If there were no XML data used for creation, nothing is done. This function calls onInit() of its children recursively (after it has inited itself). It is highly recommended to call BasicObject::onInit(), usually at the end of the onInit() method, when overwriting it in a derived class.

Reimplemented from BasicObject.


The documentation for this class was generated from the following files:
Generated on Wed May 9 17:36:34 2007 for netrinjo by  doxygen 1.5.1