ZFFramework
 
Loading...
Searching...
No Matches
ZFImpl_ZFLua.h
Go to the documentation of this file.
1
5
6#ifndef _ZFI_ZFImpl_ZFLua_h_
7#define _ZFI_ZFImpl_ZFLua_h_
8
9#include "ZFLua.h"
11
13
41
55
60 ZF_IN lua_State *L
61 , ZF_IN const ZFClassDataUpdateData &data
62 );
63
64// ============================================================
67public:
69 explicit ZFImpl_ZFLua_ImplSetupHelper(ZF_IN lua_State *L);
72public:
74 void addGlobalScope(ZF_IN const zfstring &scope);
76 void addGenericScope(ZF_IN const zfstring &genericScope);
78 void addCustomCode(ZF_IN const zfstring &code);
79private:
83 void _commit(void);
85private:
86 lua_State *_L;
87 zfstring _code;
88 void *_m;
89};
90
95 ZF_IN_OUT lua_State *L
96 , ZF_IN_OPT int metatableIndex = -1
97 );
98
99// ============================================================
100typedef void (*_ZFP_ZFImpl_ZFLua_ImplSetupAttach)(
101 ZF_IN_OUT lua_State *L
103 );
104typedef void (*_ZFP_ZFImpl_ZFLua_ImplSetupDetach)(ZF_IN_OUT lua_State *L);
105typedef void (*_ZFP_ZFImpl_ZFLua_ImplSetupClassDataUpdate)(
106 ZF_IN_OUT lua_State *L
107 , ZF_IN const ZFClassDataUpdateData &data
109 );
110extern ZFLIB_ZFLua_impl void _ZFP_ZFImpl_ZFLua_implSetupCallbackRegister(
111 ZF_IN _ZFP_ZFImpl_ZFLua_ImplSetupAttach setupAttachCallback
112 , ZF_IN _ZFP_ZFImpl_ZFLua_ImplSetupDetach setupDetachCallback
113 , ZF_IN _ZFP_ZFImpl_ZFLua_ImplSetupClassDataUpdate setupClassDataUpdate
114 );
115extern ZFLIB_ZFLua_impl void _ZFP_ZFImpl_ZFLua_implSetupCallbackUnregister(
116 ZF_IN _ZFP_ZFImpl_ZFLua_ImplSetupAttach setupAttachCallback
117 , ZF_IN _ZFP_ZFImpl_ZFLua_ImplSetupDetach setupDetachCallback
118 , ZF_IN _ZFP_ZFImpl_ZFLua_ImplSetupClassDataUpdate setupClassDataUpdate
119 );
120
145#define ZFImpl_ZFLua_implSetupCallback_DEFINE(SetupSig, setupAttachAction, setupDetachAction, setupClassDataUpdate) \
146 ZF_GLOBAL_INITIALIZER_INIT_WITH_LEVEL(ZFImpl_ZFLua_implSetupAction_##SetupSig, ZFLevelZFFrameworkLow) { \
147 _ZFP_ZFImpl_ZFLua_implSetupCallbackRegister(zfself::implSetupAttach, zfself::implSetupDetach, zfself::implSetupClassDataUpdate); \
148 } \
149 ZF_GLOBAL_INITIALIZER_DESTROY(ZFImpl_ZFLua_implSetupAction_##SetupSig) { \
150 _ZFP_ZFImpl_ZFLua_implSetupCallbackUnregister(zfself::implSetupAttach, zfself::implSetupDetach, zfself::implSetupClassDataUpdate); \
151 } \
152 public: \
153 static void implSetupAttach( \
154 ZF_IN_OUT lua_State *L \
155 , ZF_IN_OUT ZFImpl_ZFLua_ImplSetupHelper &helper \
156 ) { \
157 setupAttachAction \
158 } \
159 static void implSetupDetach(ZF_IN_OUT lua_State *L) { \
160 setupDetachAction \
161 } \
162 static void implSetupClassDataUpdate( \
163 ZF_IN_OUT lua_State *L \
164 , ZF_IN const ZFClassDataUpdateData &data \
165 , ZF_IN_OUT ZFImpl_ZFLua_ImplSetupHelper &helper \
166 ) { \
167 setupClassDataUpdate \
168 } \
169 ZF_GLOBAL_INITIALIZER_END(ZFImpl_ZFLua_implSetupAction_##SetupSig)
170
171// ============================================================
180 ZF_IN lua_State *L
181 , ZF_IN const zfchar *buf
182 , ZF_IN_OPT zfindex bufLen = zfindexMax()
183 , ZF_OUT_OPT zfauto *luaResult = zfnull
184 , ZF_IN_OPT const ZFCoreArray<zfauto> *luaParams = zfnull
185 , ZF_OUT_OPT zfstring *errHint = zfnull
186 , ZF_IN_OPT const zfchar *chunkInfo = zfnull
187 , ZF_IN_OPT const zfchar *srcInfo = zfnull
188 );
193 ZF_IN lua_State *L
194 , ZF_IN int error
195 , ZF_OUT_OPT zfstring *errHint = zfnull
196 , ZF_IN_OPT const zfchar *chunkInfo = zfnull
197 , ZF_IN_OPT zfindex errorLine = zfindexMax()
198 );
199
204 ZF_IN lua_State *L
205 , ZF_IN_OUT zfstring &ret
206 );
211 zfstring ret;
213 return ret;
214}
215
216// ============================================================
217// utils
220 ZF_OUT zfstring &ret
221 , ZF_IN lua_State *L
222 , ZF_IN int luaStackOffset
223 , ZF_IN_OPT zfbool printLuaType = zffalse
224 );
229 ZF_IN lua_State *L
230 , ZF_IN int luaStackOffset
231 , ZF_IN_OPT zfbool printLuaType = zffalse
232 ) {
233 zfstring ret;
234 ZFImpl_ZFLua_luaObjectInfoT(ret, L, luaStackOffset, printLuaType);
235 return ret;
236}
237
242 ZF_OUT zfauto &param
243 , ZF_IN lua_State *L
244 , ZF_IN int luaStackOffset
245 );
246
259 ZF_OUT zfauto &param
260 , ZF_IN lua_State *L
261 , ZF_IN int luaStackOffset
262 , ZF_OUT_OPT zfstring *errorHint = zfnull
263 );
264
273 ZF_OUT zfauto &ret
274 , ZF_IN lua_State *L
275 , ZF_IN int luaStackOffset
276 , ZF_OUT_OPT zfstring *errorHint = zfnull
277 );
278
282 , ZF_IN lua_State *L
283 , ZF_IN int luaStackOffset
284 , ZF_IN_OPT zfbool allowEmpty = zffalse
285 , ZF_OUT_OPT const ZFClass **holderCls = zfnull
286 );
295 ZF_IN lua_State *L
296 , ZF_IN int luaStackOffset
297 , ZF_IN_OPT zfbool allowEmpty = zffalse
298 , ZF_OUT_OPT const ZFClass **holderCls = zfnull
299 ) {
300 zfstring ret;
301 ZFImpl_ZFLua_toStringT(ret, L, luaStackOffset, allowEmpty, holderCls);
302 return ret;
303}
304
307 , ZF_IN ZFObject *obj
308 , ZF_IN_OPT zfbool allowEmpty = zffalse
309 , ZF_OUT_OPT const ZFClass **holderCls = zfnull
310 );
313 ZF_IN ZFObject *obj
314 , ZF_IN_OPT zfbool allowEmpty = zffalse
315 , ZF_OUT_OPT const ZFClass **holderCls = zfnull
316 ) {
317 zfstring ret;
318 ZFImpl_ZFLua_toStringT(ret, obj, allowEmpty, holderCls);
319 return ret;
320}
321
324 ZF_OUT zfauto &ret
325 , ZF_IN lua_State *L
326 , ZF_IN int luaStackOffset
327 , ZF_IN_OPT zfbool allowEmpty = zffalse
328 , ZF_OUT_OPT const ZFClass **holderCls = zfnull
329 );
340 ZF_IN lua_State *L
341 , ZF_IN int luaStackOffset
342 , ZF_IN_OPT zfbool allowEmpty = zffalse
343 , ZF_OUT_OPT const ZFClass **holderCls = zfnull
344 ) {
345 zfauto ret;
346 ZFImpl_ZFLua_toNumberT(ret, L, luaStackOffset, allowEmpty, holderCls);
347 return ret;
348}
349
352 ZF_OUT zfauto &ret
353 , ZF_IN ZFObject *obj
354 , ZF_IN_OPT zfbool allowEmpty = zffalse
355 , ZF_OUT_OPT const ZFClass **holderCls = zfnull
356 );
357
371 ZF_IN lua_State *L
372 , ZF_IN ZFObject *obj
373 , ZF_IN_OPT zfbool allowEmpty = zffalse
374 );
375
380 ZF_IN lua_State *L
382 , ZF_IN_OPT int luaParamOffset = 1
383 );
384
389 ZF_IN lua_State *L
390 , ZF_IN_OPT int luaStackOffset = 1
391 );
392
393// ============================================================
398zfclass ZFLIB_ZFLua_impl ZFImpl_ZFLuaValue : zfextend ZFObject {
399 ZFOBJECT_DECLARE(ZFImpl_ZFLuaValue, ZFObject)
400
401public:
402 lua_State *L;
404
405public:
407 virtual zfbool objectIsInternal(void) {return zftrue;}
409 virtual zfbool objectIsInternalPrivate(void) {return zftrue;}
410protected:
412 virtual void objectOnInit(void) {
414 this->L = zfnull;
415 this->luaValue = -1;
416 }
418 virtual void objectOnDeallocPrepare(void) {
419 if(L != zfnull) {
420 luaL_unref(L, LUA_REGISTRYINDEX, luaValue);
421 L = zfnull;
422 }
423 luaValue = -1;
425 }
429 if(L != zfnull && luaValue != -1) {
430 lua_rawgeti(L, LUA_REGISTRYINDEX, luaValue);
431 ret += " luaValue=";
433 lua_pop(L, 1);
434 }
435 }
436};
437
438// ============================================================
439// wrapper for impl
441inline lua_State *ZFImpl_ZFLua_luaOpen(void) {
442 return ELuna::openLua();
443}
444
445inline void ZFImpl_ZFLua_luaClose(ZF_IN lua_State *L) {
446 ELuna::closeLua(L);
447}
448
450template<typename T>
452 ZF_IN lua_State *L
453 , ZF_IN const zfchar *name
454 ) {
455 ELuna::registerClass<T>(L, name, ELuna::constructor<zfauto>);
456}
457
458template<typename F>
460 ZF_IN lua_State *L
461 , ZF_IN const zfchar *name
462 , ZF_IN F f
463 ) {
464 ELuna::registerFunction(L, name, f);
465}
466
468 ZF_IN lua_State *L
469 , ZF_IN const zfchar *name
470 , ZF_IN int (*f)(lua_State *)
471 ) {
472 lua_register(L, name, f);
473}
474
477 ZF_IN lua_State *L
478 , ZF_IN zfauto &v
479 ) {
480 if(v && v->classData() == v_zfbool::ClassData()) {
481 lua_pushboolean(L, zfcast(v_zfbool *, v)->zfv);
482 return;
483 }
484 ELuna::convert2LuaType<zfauto>::convertType(L, v);
485}
486
488 ZF_IN lua_State *L
489 , ZF_IN const zfauto &v
490 ) {
491 zfauto t = v;
493}
494
496 ZF_IN lua_State *L
497 , ZF_IN ZFObject *v
498 ) {
499 zfauto t = v;
501}
502
504 ZF_IN lua_State *L
505 , ZF_IN int luaStackOffset
506 ) {
507 return ELuna::convert2CppType<zfauto &>::convertType(L, luaStackOffset);
508}
509
536#define ZFImpl_ZFLua_luaErrorPrepare(L) \
537 _ZFP_ZFImpl_ZFLua_luaErrorPrepare _ZFP_ZFImpl_ZFLua_luaErrorPrepareNotCalled(L)
538zfclassNotPOD ZFLIB_ZFLua_impl _ZFP_ZFImpl_ZFLua_luaErrorPrepare {
539public:
540 _ZFP_ZFImpl_ZFLua_luaErrorPrepare(ZF_IN lua_State *L)
541 : L(L)
542 , errorHint()
543 {
544 }
545 ~_ZFP_ZFImpl_ZFLua_luaErrorPrepare(void) {
546 if(this->errorHint) {
547 lua_Debug ar;
548 for(int iStack = 1; ; ++iStack) {
549 int success = lua_getstack(L, iStack, &ar);
550 if(!success) {
551 break;
552 }
553 success = lua_getinfo(L, "nSl", &ar);
554 if(!success) {
555 break;
556 }
557 if((iStack == 2 || ar.name == NULL) && ar.currentline > 0) {
558 // pass special header to ZFImpl_ZFLua_execute_errorHandle
559 this->errorHint.insert(0, zfstr("<<{{%s}}>>", (zfindex)ar.currentline));
560 break;
561 }
562 }
563
564 zfstring info;
565 if(ZFImpl_ZFLua_stacktraceT(L, info)) {
566 this->errorHint += "\n";
567 this->errorHint += info;
568 }
569 luaL_error(L, "%s", this->errorHint.cString());
570 }
571 }
572public:
573 int luaError(
574 ZF_IN lua_State *L
575 , ZF_IN const zfchar *text
576 ) {
577 ZFCoreAssert(this->errorHint == zfnull);
578 this->errorHint += text;
579 return 0;
580 }
581private:
582 lua_State *L;
583 zfstring errorHint;
584};
585
587#define ZFImpl_ZFLua_luaError(L, fmt, ...) \
588 _ZFP_ZFImpl_ZFLua_luaErrorPrepareNotCalled.luaError(L, zfstr(fmt, ##__VA_ARGS__))
589
590zfclassLikePOD ZFLIB_ZFLua_impl _ZFP_ZFLuaStackChecker {
591public:
592 lua_State *L;
593 int stackChange;
594 int stackSaved;
595public:
596 _ZFP_ZFLuaStackChecker(
597 ZF_IN lua_State *L
598 , ZF_IN_OPT int stackChange = 0
599 )
600 : L(L), stackChange(stackChange), stackSaved(lua_gettop(L))
601 {
602 }
603 ~_ZFP_ZFLuaStackChecker(void) {
604 int cur = lua_gettop(L);
606 cur == stackSaved + stackChange,
607 "stack messed up: %s(%s) => %s",
608 stackSaved, stackChange, cur);
609 }
610};
612#if ZF_ENV_DEBUG
613 #define ZFImpl_ZFLua_DEBUG_luaStackChecker(name, L, stackChange) \
614 _ZFP_ZFLuaStackChecker _DEBUG_luaStackChecker_##name(L, stackChange)
615#else
616 #define ZFImpl_ZFLua_DEBUG_luaStackChecker(name, L, stackChange)
617#endif
618
620
621#endif // #ifndef _ZFI_ZFImpl_ZFLua_h_
622
#define ZFCoreAssertWithMessageTrim(exp, fmt,...)
see ZFCoreAssertWithMessage
Definition ZFCoreLog_CommonLog.h:81
#define ZFCoreAssert(exp)
assert exp is zftrue
Definition ZFCoreLog_CommonLog.h:47
_ZFT_t_zfchar zfchar
char wrapper
Definition ZFCoreTypeDef_CharType.h:17
#define ZF_OUT_OPT
dummy macro that shows the param used as optional output
Definition ZFCoreTypeDef_ClassType.h:192
#define zfclassLikePOD
shows the class is not a POD type, but you may use it like a POD except memset it to 0
Definition ZFCoreTypeDef_ClassType.h:41
#define zfextend
dummy macro shows class inherit from another
Definition ZFCoreTypeDef_ClassType.h:53
#define zfoverride
dummy macro shows that method override parent's method
Definition ZFCoreTypeDef_ClassType.h:58
#define ZF_IN
dummy macro that shows the param used as required input
Definition ZFCoreTypeDef_ClassType.h:180
#define ZF_IN_OPT
dummy macro that shows the param used as optional input
Definition ZFCoreTypeDef_ClassType.h:184
#define ZF_OUT
dummy macro that shows the param used as required output
Definition ZFCoreTypeDef_ClassType.h:188
#define zfclassNotPOD
shows the class is not a POD type, you should not memset it or declare it in stack or copy value by c...
Definition ZFCoreTypeDef_ClassType.h:48
#define ZF_IN_OUT
dummy macro that shows the param used as required input and output
Definition ZFCoreTypeDef_ClassType.h:196
_ZFT_t_zfbool zfbool
bool type
Definition ZFCoreTypeDef_CoreType.h:103
_ZFT_t_zfindex zfindex
similar to size_t, used for index and size only
Definition ZFCoreTypeDef_CoreType.h:154
#define zftrue
bool true type
Definition ZFCoreTypeDef_CoreType.h:107
#define zfindexMax()
(zfindex)-1, indicate a max index value, see zfindex
Definition ZFCoreTypeDef_CoreType.h:159
#define zffalse
bool false type
Definition ZFCoreTypeDef_CoreType.h:111
#define zfnull
same as NULL, defined for future use
Definition ZFCoreTypeDef_CoreType.h:88
zft_zfstring< zfchar > zfstring
see zft_zfstring
Definition ZFCoreTypeDef_StringType.h:15
zfbool ZFImpl_ZFLua_execute(lua_State *L, const zfchar *buf, zfindex bufLen=((zfindex) -1), zfauto *luaResult=zft_zfnull, const ZFCoreArray< zfauto > *luaParams=zft_zfnull, zfstring *errHint=zft_zfnull, const zfchar *chunkInfo=zft_zfnull, const zfchar *srcInfo=zft_zfnull)
run lua code, L must be first initialized by ZFImpl_ZFLua_luaStateAttach
void ZFImpl_ZFLua_classDataUpdate(lua_State *L, const ZFClassDataUpdateData &data)
called when class data changed, for each lua state of each thread
void ZFImpl_ZFLua_luaStateAttach(lua_State *L)
see ZFImpl_ZFLua_luaStateOpen
void ZFImpl_ZFLua_execute_errorHandle(lua_State *L, int error, zfstring *errHint=zft_zfnull, const zfchar *chunkInfo=zft_zfnull, zfindex errorLine=((zfindex) -1))
error handler for ZFImpl_ZFLua_execute, lua_pcall, etc
zfbool ZFImpl_ZFLua_zfstringAppend(lua_State *L, zfstring &s, int luaParamOffset=1)
append with va_arg, see ZFLuaExecute
void ZFImpl_ZFLua_implSetupMetatable(lua_State *L, int metatableIndex=-1)
setup metatable for zfauto in lua env
zfstring ZFImpl_ZFLua_luaStackInfo(lua_State *L, int luaStackOffset=1)
return info of current stack
zfstring ZFImpl_ZFLua_stacktrace(lua_State *L)
get lua stacktrace
Definition ZFImpl_ZFLua.h:210
void ZFImpl_ZFLua_luaStateDetach(lua_State *L)
see ZFImpl_ZFLua_luaStateAttach
zfbool ZFImpl_ZFLua_toGeneric(zfauto &param, lua_State *L, int luaStackOffset, zfstring *errorHint=zft_zfnull)
get params from lua
zfstring ZFImpl_ZFLua_toString(lua_State *L, int luaStackOffset, zfbool allowEmpty=_ZFT_t_zffalse, const ZFClass **holderCls=zft_zfnull)
get params from lua
Definition ZFImpl_ZFLua.h:294
lua_State * ZFImpl_ZFLua_luaOpen(void)
util for impl
Definition ZFImpl_ZFLua.h:441
void ZFImpl_ZFLua_luaStateClose(lua_State *L)
see ZFImpl_ZFLua_luaStateOpen
zfbool ZFImpl_ZFLua_toLuaValue(lua_State *L, ZFObject *obj, zfbool allowEmpty=_ZFT_t_zffalse)
convert native type to lua type
void ZFImpl_ZFLua_luaCFunctionRegister(lua_State *L, const zfchar *name, int(*f)(lua_State *))
util for impl
Definition ZFImpl_ZFLua.h:467
zfbool ZFImpl_ZFLua_toStringT(zfstring &s, lua_State *L, int luaStackOffset, zfbool allowEmpty=_ZFT_t_zffalse, const ZFClass **holderCls=zft_zfnull)
see ZFImpl_ZFLua_toString
zfbool ZFImpl_ZFLua_toCallback(zfauto &ret, lua_State *L, int luaStackOffset, zfstring *errorHint=zft_zfnull)
get params from lua
void ZFImpl_ZFLua_luaClose(lua_State *L)
util for impl
Definition ZFImpl_ZFLua.h:445
zfbool ZFImpl_ZFLua_stacktraceT(lua_State *L, zfstring &ret)
get lua stacktrace
void ZFImpl_ZFLua_luaPush(lua_State *L, zfauto &v)
util for impl
Definition ZFImpl_ZFLua.h:476
zfauto ZFImpl_ZFLua_toNumber(lua_State *L, int luaStackOffset, zfbool allowEmpty=_ZFT_t_zffalse, const ZFClass **holderCls=zft_zfnull)
get params from lua
Definition ZFImpl_ZFLua.h:339
void * ZFImpl_ZFLua_luaStateOpen(void)
create new lua state
void ZFImpl_ZFLua_luaObjectInfoT(zfstring &ret, lua_State *L, int luaStackOffset, zfbool printLuaType=_ZFT_t_zffalse)
see ZFImpl_ZFLua_luaObjectInfo
zfbool ZFImpl_ZFLua_toNumberT(zfauto &ret, lua_State *L, int luaStackOffset, zfbool allowEmpty=_ZFT_t_zffalse, const ZFClass **holderCls=zft_zfnull)
see ZFImpl_ZFLua_toNumber
zfauto & ZFImpl_ZFLua_luaGet(lua_State *L, int luaStackOffset)
util for impl
Definition ZFImpl_ZFLua.h:503
void ZFImpl_ZFLua_luaClassRegister(lua_State *L, const zfchar *name)
util for impl
Definition ZFImpl_ZFLua.h:451
zfbool ZFImpl_ZFLua_toObject(zfauto &param, lua_State *L, int luaStackOffset)
get params from lua
void ZFImpl_ZFLua_luaFunctionRegister(lua_State *L, const zfchar *name, F f)
util for impl
Definition ZFImpl_ZFLua.h:459
zfstring ZFImpl_ZFLua_luaObjectInfo(lua_State *L, int luaStackOffset, zfbool printLuaType=_ZFT_t_zffalse)
get raw lua object info
Definition ZFImpl_ZFLua.h:228
global header for ZFLua_impl module
#define ZFLIB_ZFLua_impl
used to export symbols
Definition ZFImpl_ZFLua_impl.h:16
header file for ZFLua module
#define ZF_NAMESPACE_GLOBAL_BEGIN
begin namespace ZFFramework
Definition ZFNamespace.h:97
#define ZF_NAMESPACE_GLOBAL_END
end namespace ZFFramework
Definition ZFNamespace.h:98
#define zfcast(T_To, obj)
safely cast ZFObject types, return null if not desired type
Definition ZFObjectCast.h:28
#define zfclass
same as class, shows that this class is a ZFObject type
Definition ZFObjectClassTypeFwd.h:38
#define ZFOBJECT_DECLARE(ChildClass, SuperClass,...)
necessary for every class inherit from ZFObject
Definition ZFObjectDeclare.h:126
data holder for ZFGlobalEvent::E_ClassDataUpdate
Definition ZFObjectClassTypeFwd.h:143
ZFObject's class info.
Definition ZFClass.h:67
light weight array
Definition ZFCoreArray.h:331
see ZFImpl_ZFLua_luaStateOpen
Definition ZFImpl_ZFLua.h:66
void addGenericScope(const zfstring &genericScope)
see ZFImpl_ZFLua_luaStateOpen
void addCustomCode(const zfstring &code)
see ZFImpl_ZFLua_luaStateOpen
void addGlobalScope(const zfstring &scope)
see ZFImpl_ZFLua_luaStateOpen
int luaValue
the lua value ref
Definition ZFImpl_ZFLua.h:403
virtual void objectOnDeallocPrepare(void)
called before objectOnDealloc, safe to call virtual functions here
Definition ZFImpl_ZFLua.h:418
virtual zfbool objectIsInternalPrivate(void)
whether this object is internal private object or its class is ZFClass::classIsInternalPrivate
Definition ZFImpl_ZFLua.h:409
virtual zfbool objectIsInternal(void)
whether this object is internal object or its class is ZFClass::classIsInternal
Definition ZFImpl_ZFLua.h:407
virtual void objectOnInit(void)
override this to init your object
Definition ZFImpl_ZFLua.h:412
lua_State * L
the lua state
Definition ZFImpl_ZFLua.h:402
virtual void objectInfoImplAppend(zfstring &ret)
see objectInfo
Definition ZFImpl_ZFLua.h:427
base class of all objects
Definition ZFObjectCore.h:209
virtual void objectOnInit(void)
override this to init your object
virtual void objectInfoImplAppend(zfstring &ret)
see objectInfo
Definition ZFObjectCore.h:331
virtual void objectOnDeallocPrepare(void)
called before objectOnDealloc, safe to call virtual functions here
Definition ZFObjectCore.h:758
type wrapper for ZFTypeId::Value
Definition ZFTypeId_CoreType.h:128
static const ZFClass * ClassData(void)
get class info
Definition ZFTypeId_CoreType.h:128
a ZFObject holder which would release content object automatically when destroyed
Definition zfautoFwd.h:34
zfstring zfstr(const zfchar *fmt=zft_zfnull)
string format util
Definition zfstr.h:59