5#ifndef _ZFI_ZFCoreStaticRegister_h_
6#define _ZFI_ZFCoreStaticRegister_h_
12#if _ZFP_ZFCoreStaticRegister_DEBUG
14 #define _ZFP_ZFCoreStaticRegister_invokeTimeLogger(fmt, ...) \
15 zfimplInvokeTimeLogger("[ZFSR] " fmt \
19 #define _ZFP_ZFCoreStaticRegister_invokeTimeLogger(fmt, ...)
43#define ZF_STATIC_REGISTER_INIT(Name) \
44 ZFLIB_HIDDEN_BEGIN() \
46 zfclassNotPOD _ZFP_R_##Name { \
48 typedef _ZFP_R_##Name zfself; \
52#define ZF_STATIC_REGISTER_DESTROY(Name) \
55#define ZF_STATIC_REGISTER_END(Name) \
57 static _ZFP_R_##Name _ZFP_RI_##Name; \
61#define ZF_STATIC_REGISTER_INSTANCE(Name) \
64#if _ZFP_ZFCoreStaticRegister_DEBUG
65 #undef ZF_STATIC_REGISTER_INIT
66 #undef ZF_STATIC_REGISTER_DESTROY
67 #undef ZF_STATIC_REGISTER_END
69 #define ZF_STATIC_REGISTER_INIT(Name) \
70 ZFLIB_HIDDEN_BEGIN() \
72 zfclassNotPOD _ZFP_R_##Name { \
74 typedef _ZFP_R_##Name zfself; \
76 _ZFP_R_##Name(void) { \
77 _ZFP_ZFCoreStaticRegister_invokeTimeLogger("reg: %s", #Name); \
81 #define ZF_STATIC_REGISTER_DESTROY(Name) \
82 ~_ZFP_R_##Name(void) { \
83 _ZFP_ZFCoreStaticRegister_invokeTimeLogger("unreg: %s", #Name); \
86 void _ZFP_R_Unreg(void)
87 #define ZF_STATIC_REGISTER_END(Name) \
89 static _ZFP_R_##Name _ZFP_RI_##Name; \
#define ZF_NAMESPACE_GLOBAL_BEGIN
begin namespace ZFFramework
Definition ZFNamespace.h:97
#define ZF_NAMESPACE_GLOBAL_END
end namespace ZFFramework
Definition ZFNamespace.h:98
minimal log util for internal debug use only