ObjectMapEventBroadcaster broadcasts inserted, removed and deleted events of ObjectMap.
#include <GCF3/ObjectMap>. More...
Public Member Functions | |
void | addListener (ObjectMapEventListener *listener) |
void | removeListener (ObjectMapEventListener *listener) |
void | removeAllListeners () |
ObjectMapEventListener * | listenerAt (int index) const |
QString | listenerType () const |
void | objectInserted (QObject *obj) |
void | objectRemoved (QObject *obj) |
void | objectDeleted (QObject *obj) |
![]() | |
ObjectMapEventListener () | |
virtual | ~ObjectMapEventListener () |
Detailed Description
ObjectMapEventBroadcaster broadcasts inserted, removed and deleted events of ObjectMap to all the GCF::ObjectMapEventListener s added to it. You can add or remove a GCF::ObjectMapEventListener to this using addListener(ObjectMapEventListener *listener) or removeListener(ObjectMapEventListener *listener) functions.
This class inherits from GCF::ObjectMapEventListener. To sent notifications to GCF::ObjectMapEventListeners added to this; you first need to set event broadcaster as GCF::ObjectMapEventListener of the GCF::ObjectMap.
Member Function Documentation
GCF::ObjectMapEventBroadcaster::addListener | ( | ObjectMapEventListener * | listener | ) |
Adds the GCF::ObjectMapEventListener to the broadcast list. From this onwards the added event listener will also get notifications for events on currently listening GCF::ObjectMap.
- Parameters
-
listener GCF::ObjectMapEventListener that needs to be added to the broadcast list.
GCF::ObjectMapEventBroadcaster::removeListener | ( | ObjectMapEventListener * | listener | ) |
Removes the GCF::ObjectMapEventListener from the broadcast list.
- Parameters
-
listener GCF::ObjectMapEventListener that needs to be removed from the broadcast list.
GCF::ObjectMapEventBroadcaster::removeAllListeners | ( | ) |
Removes all ObjectMapEventListener's from the broadcast list.
GCF::ObjectMapEventBroadcaster::listenerAt | ( | int | index | ) | const |
Returns the GCF::ObjectMapEventListener at the specified index.
- Parameters
-
index index of which GCF::ObjectMapEventListener needs to be returned.
- Returns
- ObjectMapEventListener at the specified index.
|
virtual |
Returns the listener type of this class. Default listener type is "GCF::ObjectMapEventBroadcaster".
- Returns
- listener type string.
Reimplemented from GCF::ObjectMapEventListener.
|
virtual |
By default there is no implementation. This function will be called when an QObject
pointer - Value pair is inserted into the listening GCF::ObjectMap.
- Parameters
-
obj QObject
pointer - Value pair which was inserted into the GCF::ObjectMap.
Reimplemented from GCF::ObjectMapEventListener.
|
virtual |
By default there is no implementation. This function will be called when an QObject
pointer is removed from the GCF::ObjectMap.
- Parameters
-
obj QObject
pointer which was removed from the listening GCF::ObjectMap.
Reimplemented from GCF::ObjectMapEventListener.
|
virtual |
By default there is no implementation. This function will be called when QObject
pointer inside the listening ObjectMap is deleted inside application.
- Parameters
-
obj QObject
pointer which got deleted.
Reimplemented from GCF::ObjectMapEventListener.