#include <CCNotificationCenter.h>
Public Member Functions | |
NotificationObserver (Object *target, SEL_CallFuncO selector, const char *name, Object *sender) | |
NotificationObserver constructor. More... | |
~NotificationObserver () | |
NotificationObserver destructor function. More... | |
void | performSelector (Object *sender) |
Invokes the callback function of this observer. More... | |
Object * | getTarget () const |
SEL_CallFuncO | getSelector () const |
const char * | getName () const |
Object * | getSender () const |
int | getHandler () const |
void | setHandler (int handler) |
![]() | |
Object () | |
Constructor. More... | |
virtual | ~Object () |
void | release () |
Release the ownership immediately. More... | |
void | retain () |
Retains the ownership. More... | |
Object * | autorelease () |
Release the ownership sometime soon automatically. More... | |
bool | isSingleReference () const |
Returns a boolean value that indicates whether there is only one reference to the object. More... | |
unsigned int | retainCount () const |
Returns the object's current reference count. More... | |
virtual bool | isEqual (const Object *object) |
Returns a boolean value that indicates whether this object and a given object are equal. More... | |
virtual void | acceptVisitor (DataVisitor &visitor) |
virtual void | update (float dt) |
Additional Inherited Members | |
![]() | |
unsigned int | _ID |
object id, ScriptSupport need public _ID More... | |
int | _luaID |
Lua reference id. More... | |
![]() | |
unsigned int | _reference |
count of references More... | |
var | _reference |
count of references More... | |
local | _reference |
count of references More... | |
unsigned int | _autoReleaseCount |
count of autorelease More... | |
var | _autoReleaseCount |
count of autorelease More... | |
local | _autoReleaseCount |
count of autorelease More... | |
NotificationObserver | ( | Object * | target, |
SEL_CallFuncO | selector, | ||
const char * | name, | ||
Object * | sender | ||
) |
NotificationObserver constructor.
target | The target which wants to observer notification events. |
selector | The callback function which will be invoked when the specified notification event was posted. |
name | The name of this notification. |
sender | The object whose notifications the target wants to receive. Only notifications sent by this sender are delivered to the target. NULL means that the sender is not used to decide whether to deliver the notification to target. |
~NotificationObserver | ( | ) |
NotificationObserver destructor function.
int getHandler | ( | ) | const |
const char* getName | ( | ) | const |
SEL_CallFuncO getSelector | ( | ) | const |
Object* getSender | ( | ) | const |
Object* getTarget | ( | ) | const |
void performSelector | ( | Object * | sender) |
Invokes the callback function of this observer.
void setHandler | ( | int | handler) |