#include <CCObject.h>
Public Member Functions | |
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... | |
unsigned int | getReferenceCount () const |
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) |
Public Attributes | |
unsigned int | _ID |
object id, ScriptSupport need public _ID More... | |
int | _luaID |
Lua reference id. More... | |
Protected Attributes | |
unsigned int | _referenceCount |
count of references More... | |
Friends | |
class | AutoreleasePool |
Object | ( | ) |
Constructor.
The object's reference count is 1 after construction.
|
virtual |
|
virtual |
Object* autorelease | ( | ) |
Release the ownership sometime soon automatically.
This descrements the object's reference count at the end of current autorelease pool block.
If the reference count reaches 0 after the descrement, this object is destructed.
unsigned int getReferenceCount | ( | ) | const |
|
virtual |
Returns a boolean value that indicates whether this object and a given object are equal.
object | The object to be compared to this object. |
object
are equal, otherwise false. Reimplemented in __String.
bool isSingleReference | ( | ) | const |
Returns a boolean value that indicates whether there is only one reference to the object.
That is, whether the reference count is 1.
void release | ( | ) |
Release the ownership immediately.
This decrements the object's reference count.
If the reference count reaches 0 after the descrement, this object is destructed.
|
inline |
|
inline |
Returns the object's current reference count.
|
inlinevirtual |
Reimplemented in Node, TargetedAction, Animate, ReverseTime, DelayTime, TintBy, TintTo, FadeTo, FadeOut, FadeIn, Blink, ScaleTo, EaseBackInOut, BezierBy, EaseBackOut, EaseBackIn, EaseBounceInOut, JumpBy, EaseBounceOut, EaseBounceIn, SkewTo, EaseElasticInOut, EaseElasticOut, EaseCubicActionInOut, MoveBy, EaseCubicActionOut, EaseElasticIn, ParticleSystem, SplitCols, EaseCubicActionIn, RotateBy, SplitRows, EaseCircleActionInOut, Twirl, EaseSineInOut, JumpTiles3D, RotateTo, EaseCircleActionOut, CallFunc, ScrollView, EaseSineOut, EaseCircleActionIn, CCBEaseInstant, Waves, Spawn, WavesTiles3D, CCBRotateYTo, EaseSineIn, EaseQuinticActionInOut, DeccelAmplitude, CCBRotateXTo, Liquid, Place, TurnOffTiles, EaseExponentialInOut, EaseQuinticActionOut, CCBRotateTo, AccelAmplitude, EaseExponentialOut, EaseQuinticActionIn, Shaky3D, FlipY, CCBSoundEffect, CardinalSplineTo, EaseExponentialIn, EaseQuarticActionInOut, AccelDeccelAmplitude, CCBSetSpriteFrame, Ripple3D, ArmatureAnimation, FlipX, Repeat, EaseQuarticActionOut, Armature, EaseInOut, Scheduler, RemoveSelf, EaseQuarticActionIn, PageView, EaseOut, FadeOutTRTiles, Bone, Lens3D, ActionManager, OrbitCamera, TextField, ToggleVisibility, Sequence, EaseQuadraticActionInOut, EaseIn, FlipY3D, ProcessBase, ShuffleTiles, Hide, EaseQuadraticActionOut, Timer, MotionStreak, Action, ProgressFromTo, FlipX3D, ControlStepper, ActionTween, Scene, Show, ShatteredTiles3D, EaseQuadraticActionIn, Skeleton, SkeletonAnimation, ComController, Waves3D, ScheduleHandlerDelegate, ActionEase, ActionInstant, Component, PageTurn3D, ProgressTo, ShakyTiles3D, EaseBezierAction, and SimpleRunLoop.
|
friend |
unsigned int _ID |
object id, ScriptSupport need public _ID
int _luaID |
Lua reference id.
|
protected |
count of references