base class of all objects More...
#include <ZFObjectCore.h>
Public Types | |
enum | |
Public Member Functions | |
virtual const ZFClass * | classData (void) |
get instance's class info | |
zfindex | objectRetainCount (void) |
return the object's retain count | |
void | objectInfoOfInstanceT (zfstring &ret) |
see objectInfoOfInstance | |
zfstring | objectInfoOfInstance (void) |
return a short string describe the object instance | |
void | objectInfoT (zfstring &ret) |
see objectInfo | |
zfstring | objectInfo (void) |
return object info | |
zfidentity | objectHash (void) |
get hash of this object | |
ZFCompareResult | objectCompare (ZFObject *anotherObj) |
compare with anotherObj | |
ZFCompareResult | objectCompareValue (ZFObject *anotherObj) |
explicitly compare object by logical value, see objectCompare | |
virtual zfauto | invoke (const zfstring &methodName) |
util method to perform ZFDI_invoke, do nothing if fail | |
virtual zfauto | invoke (const zfstring &methodName, ZFObject *param0, ZFObject *param1=((ZFObject *const &) _ZFP_ZFMP_DEF), ZFObject *param2=((ZFObject *const &) _ZFP_ZFMP_DEF), ZFObject *param3=((ZFObject *const &) _ZFP_ZFMP_DEF), ZFObject *param4=((ZFObject *const &) _ZFP_ZFMP_DEF), ZFObject *param5=((ZFObject *const &) _ZFP_ZFMP_DEF), ZFObject *param6=((ZFObject *const &) _ZFP_ZFMP_DEF), ZFObject *param7=((ZFObject *const &) _ZFP_ZFMP_DEF)) |
util method to perform ZFDI_invoke, do nothing if fail | |
virtual zfbool | invokeT (zfauto &ret, zfstring *errorHint, const zfstring &methodName, ZFObject *param0=((ZFObject *const &) _ZFP_ZFMP_DEF), ZFObject *param1=((ZFObject *const &) _ZFP_ZFMP_DEF), ZFObject *param2=((ZFObject *const &) _ZFP_ZFMP_DEF), ZFObject *param3=((ZFObject *const &) _ZFP_ZFMP_DEF), ZFObject *param4=((ZFObject *const &) _ZFP_ZFMP_DEF), ZFObject *param5=((ZFObject *const &) _ZFP_ZFMP_DEF), ZFObject *param6=((ZFObject *const &) _ZFP_ZFMP_DEF), ZFObject *param7=((ZFObject *const &) _ZFP_ZFMP_DEF)) |
util method to perform ZFDI_invoke, do nothing if fail | |
virtual zfauto | invokeDetail (const zfstring &methodName, const ZFCoreArray< zfauto > ¶ms, zfbool *success=zft_zfnull, zfstring *errorHint=zft_zfnull) |
util method to perform ZFDI_invoke, do nothing if fail | |
zfbool | objectTagExist (void) |
see objectTag, true if this object has tag, and tag can be checked by objectTagGetAllKeyValue | |
void | objectTag (const zfstring &key, ZFObject *tag) |
used to hold a object for app's use, auto retained | |
zfany | objectTag (const zfstring &key) |
see objectTag | |
void | objectTagGetAllKeyValue (ZFCoreArray< zfstring > &allKey, ZFCoreArray< zfauto > &allValue) |
get all key value | |
void | objectTagRemove (const zfstring &key) |
remove tag, same as set tag to null | |
zfauto | objectTagRemoveAndGet (const zfstring &key) |
remove tag, return removed tag or null if not exist | |
void | objectTagRemoveAll (void) |
remove all tag | |
void | observerAdd (zfidentity eventId, const ZFListener &observer, ZFLevel observerLevel=ZFLevelAppNormal) |
see observerNotify | |
void | observerAddForOnce (zfidentity eventId, const ZFListener &observer, ZFLevel observerLevel=ZFLevelAppNormal) |
see observerNotify | |
void | observerRemove (zfidentity eventId, const ZFListener &callback) |
see observerNotify | |
void | observerRemoveAll (zfidentity eventId) |
see observerNotify | |
void | observerRemoveAll (void) |
see observerNotify | |
zfbool | observerHasAdd (void) |
true if any observer has been added | |
zfbool | observerHasAdd (zfidentity eventId) |
true if any observer with eventId has been added | |
void | observerNotify (zfidentity eventId, ZFObject *param0=zft_zfnull, ZFObject *param1=zft_zfnull) |
notify the observer with eventId | |
void | observerNotifyWithSender (ZFObject *customSender, zfidentity eventId, ZFObject *param0=zft_zfnull, ZFObject *param1=zft_zfnull) |
see observerNotify | |
void | observerNotifyReversely (zfidentity eventId, ZFObject *param0=zft_zfnull, ZFObject *param1=zft_zfnull) |
see observerNotify | |
void | observerNotifyReverselyWithSender (ZFObject *customSender, zfidentity eventId, ZFObject *param0=zft_zfnull, ZFObject *param1=zft_zfnull) |
see observerNotify | |
ZFObserver & | observerHolder (void) |
access the internal observer holder | |
void | on (const zfstring &eventName, const ZFListener &observer, ZFLevel observerLevel=ZFLevelAppNormal) |
util to observerAdd | |
void | on (zfidentity eventId, const ZFListener &observer, ZFLevel observerLevel=ZFLevelAppNormal) |
util to observerAdd | |
void | onInit (const ZFListener &impl) |
util for script to achieve chained call | |
void | onDealloc (const ZFListener &impl) |
util for script to achieve chained call | |
zfbool | objectInstanceStateCheck (ZFObjectInstanceState state) |
object instance's state | |
zfbool | objectInitRunning (void) |
util method to check whether ZFObjectInstanceStateOnInit or ZFObjectInstanceStateOnInitFinish running | |
zfbool | objectDeallocRunning (void) |
util method to check whether ZFObjectInstanceStateOnDeallocPrepare or ZFObjectInstanceStateOnDealloc running | |
virtual zfbool | objectIsInternal (void) |
whether this object is internal object or its class is ZFClass::classIsInternal | |
virtual zfbool | objectIsInternalPrivate (void) |
whether this object is internal private object or its class is ZFClass::classIsInternalPrivate | |
Static Public Member Functions | |
static const ZFClass * | ClassData (void) |
get class info | |
static zfidentity | E_ObjectBeforeAlloc (void) |
see ZFObject::observerNotify | |
static zfidentity | E_ObjectAfterAlloc (void) |
see ZFObject::observerNotify | |
static zfidentity | E_ObjectBeforeDealloc (void) |
see ZFObject::observerNotify | |
static zfidentity | E_ObjectPropertyValueOnUpdate (void) |
see ZFObject::observerNotify | |
static zfidentity | E_ObjectPropertyValueOnReset (void) |
see ZFObject::observerNotify | |
Protected Types | |
typedef _ZFP_Obj_Base | zfsuper |
class ref to super | |
typedef ZFObject | zfself |
class ref to self | |
Protected Member Functions | |
virtual void | objectInfoImpl (zfstring &ret) |
see objectInfo | |
virtual void | objectInfoImplAppend (zfstring &ret) |
see objectInfo | |
virtual zfidentity | objectHashImpl (void) |
see objectHash | |
virtual ZFCompareResult | objectCompareImpl (ZFObject *anotherObj) |
see objectCompare | |
virtual ZFCompareResult | objectCompareValueImpl (ZFObject *anotherObj) |
see objectCompareValue | |
virtual void | observerOnAdd (zfidentity eventId) |
called when add first observer | |
virtual void | observerOnRemove (zfidentity eventId) |
called when remove last observer | |
virtual void | observerOnEvent (const ZFArgs &zfargs) |
notified when observerNotify | |
virtual void | objectOnInit (void) |
override this to init your object | |
virtual void | objectOnInitFinish (void) |
called after objectOnInit, safe to call virtual functions here | |
virtual void | objectOnDeallocPrepare (void) |
called before objectOnDealloc, safe to call virtual functions here | |
virtual void | objectOnDealloc (void) |
override this to destroy your object | |
virtual void | objectOnRetain (void) |
called to retain object | |
virtual void | objectOnRelease (void) |
called to release object | |
virtual void | objectPropertyValueOnUpdate (const ZFProperty *property, const void *oldValue) |
see E_ObjectPropertyValueOnUpdate | |
virtual void | objectPropertyValueOnReset (const ZFProperty *property) |
see E_ObjectPropertyValueOnReset | |
Friends | |
class | ZFClass |
class | ZFObserver |
base class of all objects
ADVANCED:
we use macros everywhere to achieve goals, there are many types and functions and whatever-it-is, which are generated by macros and are private, you should never ever access it in your code
here's a list or them:
|
inlinevirtual |
get instance's class info
Reimplemented in v_ZFAniForNativeCurve, v_ZFArgs, v_ZFBezier, v_zfbool, v_zfboolHolder, v_zfbyte, v_ZFCallback, v_ZFCallbackType, v_ZFCallerInfo, v_zfchar, v_ZFClass, v_ZFClassDataUpdateData, v_ZFClassDataUpdateType, v_ZFClassInstanceObserverAddParam, v_ZFComparer_ZFObject, v_ZFCompareResult, v_ZFCompressLevel, v_ZFCoreArray, v_zfdouble, v_ZFDynamic, v_ZFEnvDeviceUIType, v_ZFFileFindData, v_ZFFileOpenOption, v_ZFFilterForIdentity, v_ZFFilterForIndex, v_ZFFilterForNumber, v_ZFFilterForString, v_ZFFilterForZFClass, v_ZFFilterForZFClassType, v_ZFFilterForZFMethod, v_ZFFilterForZFObject, v_ZFFilterForZFProperty, v_ZFFilterResult, v_ZFFilterType, v_zfflags, v_zffloat, v_ZFFrameworkState, v_ZFFuncAddrType, v_ZFHttpMethod, v_zfidentity, v_ZFIdentityGenerator, v_zfindex, v_ZFIndexRange, v_zfint, v_zfiter, v_ZFJson, v_ZFJsonOutputToken, v_ZFJsonType, v_ZFLevel, v_ZFLogLevel, v_zflong, v_ZFMethod, v_ZFMethodAccessType, v_ZFMethodDynamicRegisterParam, v_ZFMethodGenericInvoker, v_ZFMethodType, v_ZFMP, v_ZFObjectInstanceState, v_ZFObserver, v_ZFObserverGroup, v_ZFOutputFormatStep, v_ZFPathInfo, v_ZFPathInfoImpl, v_ZFProperty, v_ZFPropertyCallbackDynamicRegisterInitValueGetter, v_ZFPropertyDynamicRegisterParam, v_ZFProtocol, v_ZFProtocolImplInfo, v_ZFProtocolInstanceState, v_ZFProtocolLevel, v_zfptr, v_ZFRegExpOption, v_ZFRegExpResult, v_ZFResultType, v_ZFSDOutputToken, v_ZFSeekPos, v_ZFSerializableData, v_ZFSerializablePropertyType, v_zfstring, v_ZFStringEncoding, v_ZFTcpType, v_ZFTextTemplateIndexData, v_ZFTextTemplateIndexFlag, v_ZFTextTemplateParam, v_ZFTextTemplateRunParam, v_ZFTimeInfo, v_zftimet, v_ZFTimeValue, v_ZFTokenForContainer, v_ZFTokenForKeyValueContainer, v_ZFUdpAddr, v_ZFUIAlign, v_ZFUIAutoLayoutPos, v_ZFUIAutoLayoutRule, v_ZFUIButtonGroupType, v_ZFUIButtonState, v_ZFUICellUpdaterParam, v_ZFUIColor, v_ZFUIImageImplNinePatchPos, v_ZFUIImageStateImplAction, v_ZFUIKeyAction, v_ZFUIKeyCode, v_ZFUIMargin, v_ZFUIMouseAction, v_ZFUIMouseButton, v_zfuint, v_ZFUIOrientation, v_ZFUIPagePauseReason, v_ZFUIPageResumeReason, v_ZFUIPoint, v_ZFUIRect, v_ZFUIScaleType, v_ZFUIScrollViewState, v_ZFUISize, v_ZFUISizeParam, v_ZFUISizeType, v_ZFUITextAppearance, v_ZFUITextEditKeyboardReturnAction, v_ZFUITextEditKeyboardReturnType, v_ZFUITextEditKeyboardType, v_ZFUITextTruncateMode, v_ZFUITransform, v_ZFUIViewBlinkParam, v_ZFUIViewChildLayer, v_ZFUIViewFocusNextParam, v_ZFUIWindowLevel, v_zfulong, v_zfweak, v_ZFXml, v_ZFXmlOutputToken, v_ZFXmlType, ZFAniForFrame, ZFAniForGeneric, ZFAniForImpl, ZFAniForNative, ZFAniForTimer, ZFAniGroup, ZFAnimation, ZFAniQueue, ZFAniTask, ZFArray, ZFAsyncIOCustomTask, ZFAsyncIOTask, ZFAsyncTask, ZFAudio, ZFAudioCache, ZFAudioPlayTask, ZFAutoReleasePool, ZFBase64, ZFCache, ZFCompress, ZFContainer, ZFCurve, ZFCurveBackIn, ZFCurveBackInOut, ZFCurveBackOut, ZFCurveBounceIn, ZFCurveBounceInOut, ZFCurveBounceOut, ZFCurveEaseIn, ZFCurveEaseInOut, ZFCurveEaseOut, ZFCurveLinear, ZFCurveLoop, ZFCurveLoopBackIn, ZFCurveLoopBackInOut, ZFCurveLoopBackOut, ZFCurveLoopBounceIn, ZFCurveLoopBounceInOut, ZFCurveLoopBounceOut, ZFCurveLoopEaseIn, ZFCurveLoopEaseInOut, ZFCurveLoopEaseOut, ZFCurveLoopLinear, ZFDecompress, ZFDI_Wrapper, ZFDI_WrapperBase, ZFDI_WrapperRaw, ZFEnum, ZFHashMap, ZFHashSet, ZFHttpRequest, ZFHttpResponse, ZFHttpServer, ZFHttpServerTask, ZFHttpServerThreadPool, ZFImpl_ZFLuaValue, ZFIOBuffer, ZFIOBufferByCacheFile, ZFIOBufferByMemory, ZFIOCache, ZFIOCacheLoadTask, ZFKeyValueContainer, ZFLogFormat, ZFMap, ZFMutex, ZFObjectHolder, ZFOutputFormatBasic, ZFPostTask, ZFRegExp, ZFResCache, ZFSemaphore, ZFSet, ZFState, ZFStyle, ZFStyleList, ZFTask, ZFTaskGroup, ZFTaskIdBasic, ZFTaskQueue, ZFTcp, ZFTestCase, ZFThread, ZFThreadMainThread, ZFThreadPool, ZFThreadPoolForIO, ZFTime, ZFTimer, ZFTypeIdWrapper, ZFUdp, ZFUIAutoLayout, ZFUIAutoLayoutParam, ZFUIButton, ZFUIButtonBasic, ZFUIButtonGroup, ZFUICell, ZFUICellAdapterBasic, ZFUICellAdapterBasicParam, ZFUICellArray, ZFUICellView, ZFUICellViewBasic, ZFUIDialog, ZFUIDrawableView, ZFUIEvent, ZFUIFlowLayout, ZFUIFlowLayoutParam, ZFUIGlobalStyle, ZFUIGridLayout, ZFUIGridLayoutParam, ZFUIHint, ZFUIHintContentBasic, ZFUIImage, ZFUIImageLoadTask, ZFUIImageView, ZFUIImageViewExt, ZFUIKeyboardState, ZFUIKeyEvent, ZFUILayoutParam, ZFUILinearLayout, ZFUILinearLayoutParam, ZFUIListView, ZFUIListViewCellUpdater, ZFUIMouseEvent, ZFUINativeViewWrapper, ZFUIOnScreenKeyboardAutoFitLayout, ZFUIOnScreenKeyboardState, ZFUIPage, ZFUIPageManager, ZFUIRootView, ZFUIScrollerDefault, ZFUIScrollLayout, ZFUIScrollThumbDefault, ZFUIScrollView, ZFUISysWindow, ZFUITextConfig, ZFUITextEdit, ZFUITextEditWidget, ZFUITextView, ZFUIView, ZFUIViewLayout, ZFUIViewMeasureResult, ZFUIWebJSBridge, ZFUIWebView, ZFUIWheelEvent, ZFUIWindow, ZFValueHolder, ZFWaitTask, and ZFWebSocket.
|
static |
notified when object allocated (before objectOnInitFinish
this event is only designed for convenient and for debug use only, usually you should use ZFClass::instanceObserverAdd
|
static |
notified when object allocated (after objectOnInitFinish
this event is only designed for convenient and for debug use only, usually you should use ZFClass::instanceObserverAdd
|
static |
notified before object dealloc
note: the object's retain count should be 1 when this event is notified, it's safe to retain the object during this event, but it's your responsibility to ensure logic valid, after notified this event, all observer of this event would be removed, so that it's safe to release the object again to finally destroy the object
|
static |
param0 is v_ZFProperty that value changes
param1 is the old property value depends on these conditions:
called when first time accessed, and each time setter is called
|
static |
param0 is v_ZFProperty
called when ZFPropertyValueReset (before value actually reset)
note, won't be called when object dealloc
|
inline |
|
inline |
return a short string describe the object instance
may looks like this: ClassName(0x123456)
|
inline |
return object info
subclass or impl may override or supply dynamic registered method with void objectInfoImpl(zfstring &ret)
to achieve custom logic, or override objectInfoImplAppend for chained impl
|
inlineprotectedvirtual |
see objectInfo
Reimplemented in v_ZFArgs, v_ZFBezier, v_zfbool, v_zfbyte, v_ZFCallback, v_ZFCallbackType, v_ZFCallerInfo, v_zfchar, v_ZFClass, v_ZFClassDataUpdateData, v_ZFClassDataUpdateType, v_ZFClassInstanceObserverAddParam, v_ZFComparer_ZFObject, v_ZFCompareResult, v_ZFCoreArray, v_zfdouble, v_ZFDynamic, v_ZFFileFindData, v_ZFFilterForIdentity, v_ZFFilterForIndex, v_ZFFilterForNumber, v_ZFFilterForString, v_ZFFilterForZFClass, v_ZFFilterForZFClassType, v_ZFFilterForZFMethod, v_ZFFilterForZFObject, v_ZFFilterForZFProperty, v_ZFFilterResult, v_ZFFilterType, v_zfflags, v_zffloat, v_ZFFrameworkState, v_ZFFuncAddrType, v_zfidentity, v_ZFIdentityGenerator, v_zfindex, v_ZFIndexRange, v_zfint, v_zfiter, v_ZFJson, v_ZFJsonOutputToken, v_ZFLevel, v_zflong, v_ZFMethod, v_ZFMethodAccessType, v_ZFMethodDynamicRegisterParam, v_ZFMethodGenericInvoker, v_ZFMethodType, v_ZFMP, v_ZFObjectInstanceState, v_ZFObserver, v_ZFObserverGroup, v_ZFPathInfo, v_ZFPathInfoImpl, v_ZFProperty, v_ZFPropertyCallbackDynamicRegisterInitValueGetter, v_ZFPropertyDynamicRegisterParam, v_ZFProtocol, v_ZFProtocolImplInfo, v_zfptr, v_ZFRegExpResult, v_ZFSDOutputToken, v_ZFSeekPos, v_ZFSerializableData, v_ZFSerializablePropertyType, v_zfstring, v_ZFTextTemplateIndexData, v_ZFTextTemplateParam, v_ZFTextTemplateRunParam, v_ZFTimeInfo, v_zftimet, v_ZFTimeValue, v_ZFTokenForContainer, v_ZFTokenForKeyValueContainer, v_ZFUdpAddr, v_ZFUIAutoLayoutRule, v_ZFUICellUpdaterParam, v_ZFUIColor, v_ZFUIMargin, v_zfuint, v_ZFUIPoint, v_ZFUIRect, v_ZFUISize, v_ZFUISizeParam, v_ZFUIViewBlinkParam, v_ZFUIViewFocusNextParam, v_zfulong, v_zfweak, v_ZFXml, v_ZFXmlOutputToken, ZFAniTask, ZFContainer, ZFCurveBackIn, ZFCurveBackInOut, ZFCurveBackOut, ZFCurveBounceIn, ZFCurveBounceInOut, ZFCurveBounceOut, ZFCurveEaseIn, ZFCurveEaseInOut, ZFCurveEaseOut, ZFCurveLinear, ZFCurveLoop, ZFCurveLoopBackIn, ZFCurveLoopBackInOut, ZFCurveLoopBackOut, ZFCurveLoopBounceIn, ZFCurveLoopBounceInOut, ZFCurveLoopBounceOut, ZFCurveLoopEaseIn, ZFCurveLoopEaseInOut, ZFCurveLoopEaseOut, ZFCurveLoopLinear, ZFDI_WrapperBase, ZFEnum, ZFHttpServer, ZFHttpServerTask, ZFKeyValueContainer, ZFTask, ZFTaskGroup, ZFTaskQueue, ZFTcp, ZFUdp, and ZFUIViewMeasureResult.
|
inlineprotectedvirtual |
see objectInfo
Reimplemented in ZFAniForNative, ZFAniGroup, ZFAnimation, ZFAudio, ZFAutoReleasePool, ZFHttpRequest, ZFHttpResponse, ZFImpl_ZFLuaValue, ZFObjectHolder, ZFRegExp, ZFThread, ZFTime, ZFUIButtonBasic, ZFUIEvent, ZFUIHint, ZFUIImage, ZFUIImageView, ZFUIKeyboardState, ZFUIKeyEvent, ZFUILayoutParam, ZFUIMouseEvent, ZFUINativeViewWrapper, ZFUIOnScreenKeyboardState, ZFUIScrollView, ZFUITextEdit, ZFUITextView, ZFUIView, ZFUIWheelEvent, and ZFValueHolder.
zfidentity ZFObject::objectHash | ( | void | ) |
get hash of this object
by default, return a hash value of the instance pointer
zfidentity objectHashImpl(void)
, to achieve custom logic ZFCompareResult ZFObject::objectCompare | ( | ZFObject * | anotherObj | ) |
compare with anotherObj
by default, compare by instance pointer
it's recommended to override this method only for objects that only contains value types, for example, v_zfstring, v_zfindex, etc, for other complex type, it's recommended to override objectCompareValue instead
ZFCompareResult objectCompare(ZFObject *)
, to achieve custom logic ZFCompareResult ZFObject::objectCompareValue | ( | ZFObject * | anotherObj | ) |
explicitly compare object by logical value, see objectCompare
ZFCompareResult objectCompareValue(ZFObject *)
, to achieve custom logic
|
inlineprotectedvirtual |
see objectHash
Reimplemented in v_ZFArgs, v_ZFBezier, v_zfbool, v_zfbyte, v_ZFCallback, v_ZFCallbackType, v_ZFCallerInfo, v_zfchar, v_ZFClass, v_ZFClassDataUpdateData, v_ZFClassDataUpdateType, v_ZFClassInstanceObserverAddParam, v_ZFComparer_ZFObject, v_ZFCompareResult, v_ZFCoreArray, v_zfdouble, v_ZFDynamic, v_ZFFileFindData, v_ZFFilterForIdentity, v_ZFFilterForIndex, v_ZFFilterForNumber, v_ZFFilterForString, v_ZFFilterForZFClass, v_ZFFilterForZFClassType, v_ZFFilterForZFMethod, v_ZFFilterForZFObject, v_ZFFilterForZFProperty, v_ZFFilterResult, v_ZFFilterType, v_zfflags, v_zffloat, v_ZFFrameworkState, v_ZFFuncAddrType, v_zfidentity, v_ZFIdentityGenerator, v_zfindex, v_ZFIndexRange, v_zfint, v_zfiter, v_ZFJson, v_ZFJsonOutputToken, v_ZFLevel, v_zflong, v_ZFMethod, v_ZFMethodAccessType, v_ZFMethodDynamicRegisterParam, v_ZFMethodGenericInvoker, v_ZFMethodType, v_ZFMP, v_ZFObjectInstanceState, v_ZFObserver, v_ZFObserverGroup, v_ZFPathInfo, v_ZFPathInfoImpl, v_ZFProperty, v_ZFPropertyCallbackDynamicRegisterInitValueGetter, v_ZFPropertyDynamicRegisterParam, v_ZFProtocol, v_ZFProtocolImplInfo, v_zfptr, v_ZFRegExpResult, v_ZFSDOutputToken, v_ZFSeekPos, v_ZFSerializableData, v_ZFSerializablePropertyType, v_zfstring, v_ZFTextTemplateIndexData, v_ZFTextTemplateParam, v_ZFTextTemplateRunParam, v_ZFTimeInfo, v_zftimet, v_ZFTimeValue, v_ZFTokenForContainer, v_ZFTokenForKeyValueContainer, v_ZFUdpAddr, v_ZFUIAutoLayoutRule, v_ZFUICellUpdaterParam, v_ZFUIColor, v_ZFUIMargin, v_zfuint, v_ZFUIPoint, v_ZFUIRect, v_ZFUISize, v_ZFUISizeParam, v_ZFUIViewBlinkParam, v_ZFUIViewFocusNextParam, v_zfulong, v_zfweak, v_ZFXml, v_ZFXmlOutputToken, ZFDI_WrapperBase, ZFEnum, ZFRegExp, and ZFTime.
|
inlineprotectedvirtual |
see objectCompare
Reimplemented in v_ZFArgs, v_ZFBezier, v_zfbool, v_zfbyte, v_ZFCallback, v_ZFCallbackType, v_ZFCallerInfo, v_zfchar, v_ZFClass, v_ZFClassDataUpdateData, v_ZFClassDataUpdateType, v_ZFClassInstanceObserverAddParam, v_ZFComparer_ZFObject, v_ZFCompareResult, v_ZFCoreArray, v_zfdouble, v_ZFDynamic, v_ZFFileFindData, v_ZFFilterForIdentity, v_ZFFilterForIndex, v_ZFFilterForNumber, v_ZFFilterForString, v_ZFFilterForZFClass, v_ZFFilterForZFClassType, v_ZFFilterForZFMethod, v_ZFFilterForZFObject, v_ZFFilterForZFProperty, v_ZFFilterResult, v_ZFFilterType, v_zfflags, v_zffloat, v_ZFFrameworkState, v_ZFFuncAddrType, v_zfidentity, v_ZFIdentityGenerator, v_zfindex, v_ZFIndexRange, v_zfint, v_zfiter, v_ZFJson, v_ZFJsonOutputToken, v_ZFLevel, v_zflong, v_ZFMethod, v_ZFMethodAccessType, v_ZFMethodDynamicRegisterParam, v_ZFMethodGenericInvoker, v_ZFMethodType, v_ZFMP, v_ZFObjectInstanceState, v_ZFObserver, v_ZFObserverGroup, v_ZFPathInfo, v_ZFPathInfoImpl, v_ZFProperty, v_ZFPropertyCallbackDynamicRegisterInitValueGetter, v_ZFPropertyDynamicRegisterParam, v_ZFProtocol, v_ZFProtocolImplInfo, v_zfptr, v_ZFRegExpResult, v_ZFSDOutputToken, v_ZFSeekPos, v_ZFSerializableData, v_ZFSerializablePropertyType, v_zfstring, v_ZFTextTemplateIndexData, v_ZFTextTemplateParam, v_ZFTextTemplateRunParam, v_ZFTimeInfo, v_zftimet, v_ZFTimeValue, v_ZFTokenForContainer, v_ZFTokenForKeyValueContainer, v_ZFUdpAddr, v_ZFUIAutoLayoutRule, v_ZFUICellUpdaterParam, v_ZFUIColor, v_ZFUIMargin, v_zfuint, v_ZFUIPoint, v_ZFUIRect, v_ZFUISize, v_ZFUISizeParam, v_ZFUIViewBlinkParam, v_ZFUIViewFocusNextParam, v_zfulong, v_zfweak, v_ZFXml, v_ZFXmlOutputToken, ZFCurveBackIn, ZFCurveBackInOut, ZFCurveBackOut, ZFCurveBounceIn, ZFCurveBounceInOut, ZFCurveBounceOut, ZFCurveEaseIn, ZFCurveEaseInOut, ZFCurveEaseOut, ZFCurveLinear, ZFCurveLoop, ZFCurveLoopBackIn, ZFCurveLoopBackInOut, ZFCurveLoopBackOut, ZFCurveLoopBounceIn, ZFCurveLoopBounceInOut, ZFCurveLoopBounceOut, ZFCurveLoopEaseIn, ZFCurveLoopEaseInOut, ZFCurveLoopEaseOut, ZFCurveLoopLinear, ZFDI_WrapperBase, ZFEnum, ZFRegExp, and ZFTime.
|
inlineprotectedvirtual |
Reimplemented in ZFAniForFrame, ZFAniForGeneric, ZFAniForImpl, ZFAniForNative, ZFAniGroup, ZFContainer, ZFKeyValueContainer, ZFUIAutoLayoutParam, ZFUIImage, ZFUILayoutParam, and ZFValueHolder.
used to hold a object for app's use, auto retained
replace if existing, remove if tag is null
void ZFObject::objectTagRemoveAll | ( | void | ) |
remove all tag
void ZFObject::observerRemoveAll | ( | zfidentity | eventId | ) |
see observerNotify
void ZFObject::observerRemoveAll | ( | void | ) |
see observerNotify
void ZFObject::observerNotify | ( | zfidentity | eventId, |
ZFObject * | param0 = zft_zfnull, | ||
ZFObject * | param1 = zft_zfnull ) |
notify the observer with eventId
the ZFListener would be executed
it's ensured the first added observer would be executed first
use ZFGlobalObserver for global observer
for instance observer:
to pass extra params to the callback, see ZFLISTENER for more info
ZFObserver & ZFObject::observerHolder | ( | void | ) |
access the internal observer holder
usually for internal use only
calling owner object's observerAdd series is ensured same with calling the observerHolder's proper method
void ZFObject::on | ( | const zfstring & | eventName, |
const ZFListener & | observer, | ||
ZFLevel | observerLevel = ZFLevelAppNormal ) |
util to observerAdd
note, this method would recursively search event name by ZFIdMapIdForName from entire inherit tree, used for convenient only (in script for example), take care of performance
example:
|
protectedvirtual |
called when add first observer
Reimplemented in ZFUIView.
|
protectedvirtual |
called when remove last observer
Reimplemented in ZFUIView.
|
inlineprotectedvirtual |
notified when observerNotify
ensured called before any other registered observer
|
protectedvirtual |
override this to init your object
subclass must call superclass's objectOnInit before any other code if override
you may also declare objectOnInit with params like this:
Reimplemented in v_ZFArgs, v_ZFBezier, v_zfbool, v_zfbyte, v_ZFCallback, v_ZFCallbackType, v_ZFCallerInfo, v_zfchar, v_ZFClass, v_ZFClassDataUpdateData, v_ZFClassDataUpdateType, v_ZFClassInstanceObserverAddParam, v_ZFComparer_ZFObject, v_ZFCompareResult, v_ZFCoreArray, v_zfdouble, v_ZFDynamic, v_ZFFileFindData, v_ZFFilterForIdentity, v_ZFFilterForIndex, v_ZFFilterForNumber, v_ZFFilterForString, v_ZFFilterForZFClass, v_ZFFilterForZFClassType, v_ZFFilterForZFMethod, v_ZFFilterForZFObject, v_ZFFilterForZFProperty, v_ZFFilterResult, v_ZFFilterType, v_zfflags, v_zffloat, v_ZFFrameworkState, v_ZFFuncAddrType, v_zfidentity, v_ZFIdentityGenerator, v_zfindex, v_ZFIndexRange, v_zfint, v_zfiter, v_ZFJson, v_ZFJsonOutputToken, v_ZFLevel, v_zflong, v_ZFMethod, v_ZFMethodAccessType, v_ZFMethodDynamicRegisterParam, v_ZFMethodGenericInvoker, v_ZFMethodType, v_ZFMP, v_ZFObjectInstanceState, v_ZFObserver, v_ZFObserverGroup, v_ZFPathInfo, v_ZFPathInfoImpl, v_ZFProperty, v_ZFPropertyCallbackDynamicRegisterInitValueGetter, v_ZFPropertyDynamicRegisterParam, v_ZFProtocol, v_ZFProtocolImplInfo, v_zfptr, v_ZFRegExpResult, v_ZFSDOutputToken, v_ZFSeekPos, v_ZFSerializableData, v_ZFSerializablePropertyType, v_zfstring, v_ZFTextTemplateIndexData, v_ZFTextTemplateParam, v_ZFTextTemplateRunParam, v_ZFTimeInfo, v_zftimet, v_ZFTimeValue, v_ZFTokenForContainer, v_ZFTokenForKeyValueContainer, v_ZFUdpAddr, v_ZFUIAutoLayoutRule, v_ZFUICellUpdaterParam, v_ZFUIColor, v_ZFUIMargin, v_zfuint, v_ZFUIPoint, v_ZFUIRect, v_ZFUISize, v_ZFUISizeParam, v_ZFUIViewBlinkParam, v_ZFUIViewFocusNextParam, v_zfulong, v_zfweak, v_ZFXml, v_ZFXmlOutputToken, ZFAniForFrame, ZFAniForGeneric, ZFAniForImpl, ZFAniForNative, ZFAniForTimer, ZFAniGroup, ZFAnimation, ZFAniTask, ZFArray, ZFAsyncIOCustomTask, ZFAsyncIOTask, ZFAsyncTask, ZFAudio, ZFAudioPlayTask, ZFAutoReleasePool, ZFCache, ZFCompress, ZFDecompress, ZFDI_WrapperBase, ZFEnum, ZFHashMap, ZFHashSet, ZFHttpRequest, ZFHttpResponse, ZFHttpServer, ZFImpl_ZFLuaValue, ZFIOBufferByCacheFile, ZFIOBufferByMemory, ZFIOCacheLoadTask, ZFMap, ZFObjectHolder, ZFOutputFormatBasic, ZFPostTask, ZFRegExp, ZFSemaphore, ZFSet, ZFState, ZFStyleList, ZFTask, ZFTaskIdBasic, ZFTcp, ZFThread, ZFThreadPool, ZFTime, ZFTimer, ZFUdp, ZFUIAutoLayout, ZFUIButton, ZFUIButtonBasic, ZFUIButtonGroup, ZFUICellArray, ZFUICellViewBasic, ZFUIDialog, ZFUIDrawableView, ZFUIHint, ZFUIImage, ZFUIImageLoadTask, ZFUIImageView, ZFUIListView, ZFUINativeViewWrapper, ZFUIOnScreenKeyboardAutoFitLayout, ZFUIPageManager, ZFUIScrollerDefault, ZFUIScrollThumbDefault, ZFUIScrollView, ZFUISysWindow, ZFUITextEdit, ZFUITextEditWidget, ZFUITextView, ZFUIView, ZFUIWebJSBridge, ZFUIWebView, ZFUIWindow, ZFValueHolder, ZFWaitTask, and ZFWebSocket.
|
inlineprotectedvirtual |
called after objectOnInit, safe to call virtual functions here
usually used to initialize independent resources other than self's internal resources
Reimplemented in ZFUIButton, ZFUICellView, ZFUIHint, ZFUIImage, ZFUIOnScreenKeyboardAutoFitLayout, ZFUIScrollThumbDefault, ZFUISysWindow, ZFUITextEdit, and ZFUITextView.
|
inlineprotectedvirtual |
called before objectOnDealloc, safe to call virtual functions here
usually used to cleanup resources attached to this object other than self's internal resources
Reimplemented in ZFAniGroup, ZFAnimation, ZFAutoReleasePool, ZFCache, ZFCompress, ZFContainer, ZFDecompress, ZFHttpServer, ZFImpl_ZFLuaValue, ZFKeyValueContainer, ZFTask, ZFTcp, ZFTestCase, ZFThread, ZFThreadPool, ZFTimer, ZFUICellArray, ZFUIHint, ZFUIImage, ZFUIImageView, ZFUIListView, ZFUIScrollThumbDefault, ZFUIScrollView, ZFUISysWindow, ZFUIView, ZFUIWebView, ZFValueHolder, and ZFWebSocket.
|
protectedvirtual |
override this to destroy your object
subclass must call superclass's objectOnDealloc after any other code if override
see objectOnInit for more info
Reimplemented in v_ZFCoreArray, ZFAniForFrame, ZFAniForGeneric, ZFAniForImpl, ZFAniForNative, ZFAniForTimer, ZFAniGroup, ZFAnimation, ZFArray, ZFAudio, ZFAutoReleasePool, ZFCache, ZFHashMap, ZFHashSet, ZFHttpRequest, ZFHttpResponse, ZFIOBufferByCacheFile, ZFIOBufferByMemory, ZFMap, ZFRegExp, ZFSemaphore, ZFSet, ZFState, ZFStyleList, ZFTcp, ZFThread, ZFTime, ZFTimer, ZFUdp, ZFUIAutoLayout, ZFUIButton, ZFUIButtonBasic, ZFUIButtonGroup, ZFUICellArray, ZFUICellViewBasic, ZFUIDialog, ZFUIHint, ZFUIImage, ZFUIListView, ZFUIOnScreenKeyboardAutoFitLayout, ZFUIPage, ZFUIPageManager, ZFUIScrollerDefault, ZFUIScrollThumbDefault, ZFUIScrollView, ZFUISysWindow, ZFUITextEdit, ZFUITextEditWidget, ZFUITextView, ZFUIView, ZFUIWebJSBridge, ZFUIWebView, ZFUIWindow, and ZFWebSocket.
|
inlineprotectedvirtual |
called to retain object
subclass must call superclass's objectOnRetain before any other code if override
usually you should not override this method
|
inlineprotectedvirtual |
called to release object
subclass must call superclass's onRelase after any other code if override
usually you should not override this method
|
virtual |
whether this object is internal object or its class is ZFClass::classIsInternal
if objectIsInternalPrivate, then it is also objectIsInternal
Reimplemented in ZFDI_WrapperBase, ZFEnum, ZFImpl_ZFLuaValue, and ZFTypeIdWrapper.
|
virtual |
whether this object is internal private object or its class is ZFClass::classIsInternalPrivate
if objectIsInternalPrivate, then it is also objectIsInternal
Reimplemented in ZFDI_WrapperBase, ZFEnum, and ZFImpl_ZFLuaValue.
|
protectedvirtual |
see E_ObjectPropertyValueOnUpdate
oldValue should be:
Reimplemented in ZFUIImage, and ZFUILayoutParam.