ZFFramework
 
Loading...
Searching...
No Matches
ZFPropertyFwd.h File Reference

property for ZFObject type More...

#include "ZFObjectClassTypeFwd.h"
#include "zfautoFwd.h"

Go to the source code of this file.

Typedefs

typedef zfbool(* ZFPropertyCallbackIsValueAccessed) (const ZFProperty *property, zfany const &ownerObj)
 used to check whether the property has been accessed
 
typedef zfbool(* ZFPropertyCallbackIsInitValue) (const ZFProperty *property, zfany const &ownerObj, zfauto *outInitValue)
 used to check whether the property is in init value state
 
typedef void(* ZFPropertyCallbackValueReset) (const ZFProperty *property, zfany const &ownerObj)
 used to reset the property to its init state
 
typedef void(* ZFPropertyCallbackUserRegisterInitValueSetup) (const ZFProperty *property, void *v)
 for user registered property only, used to setup a property's init value
 
typedef zfauto(* ZFPropertyCallbackDynamicRegisterInitValueGetter) (const ZFProperty *property)
 callback to setup init value for ZFPropertyDynamicRegister
 

Functions

void ZFPropertyCallbackIsValueAccessedChange (const ZFProperty *property, ZFPropertyCallbackIsValueAccessed callback)
 change default impl for ZFPropertyCallbackIsValueAccessed, use with caution
 
void ZFPropertyCallbackIsInitValueChange (const ZFProperty *property, ZFPropertyCallbackIsInitValue callback)
 change default impl for ZFPropertyCallbackIsInitValue, use with caution
 
void ZFPropertyCallbackValueResetChange (const ZFProperty *property, ZFPropertyCallbackValueReset callback)
 change default impl for ZFPropertyCallbackValueReset, use with caution
 

Detailed Description

property for ZFObject type

Typedef Documentation

◆ ZFPropertyCallbackIsValueAccessed

typedef zfbool(* ZFPropertyCallbackIsValueAccessed) (const ZFProperty *property, zfany const &ownerObj)

used to check whether the property has been accessed

usage:

const ZFProperty *propertyInfo = ...;
propertyInfo->callbackIsValueAccessed(propertyInfo, ownerObj);
info for a property for ZFObject, see ZFPROPERTY_RETAIN for more info
Definition ZFProperty.h:28
ZFPropertyCallbackIsValueAccessed callbackIsValueAccessed
see ZFPropertyCallbackIsValueAccessed
Definition ZFProperty.h:171

◆ ZFPropertyCallbackIsInitValue

typedef zfbool(* ZFPropertyCallbackIsInitValue) (const ZFProperty *property, zfany const &ownerObj, zfauto *outInitValue)

used to check whether the property is in init value state

usage:

const ZFProperty *propertyInfo = ...;
propertyInfo->callbackIsInitValue(propertyInfo, ownerObj, zfnull);
#define zfnull
same as NULL, defined for future use
Definition ZFCoreTypeDef_CoreType.h:88
ZFPropertyCallbackIsInitValue callbackIsInitValue
see ZFPropertyCallbackIsInitValue
Definition ZFProperty.h:173
Note
the outInitValue can be set to access the init value (only when the checker returned false)

◆ ZFPropertyCallbackDynamicRegisterInitValueGetter

typedef zfauto(* ZFPropertyCallbackDynamicRegisterInitValueGetter) (const ZFProperty *property)

callback to setup init value for ZFPropertyDynamicRegister

returned object must be valid to ZFTypeInfo::typeIdClass