diff options
author | chai <chaifix@163.com> | 2021-10-17 23:05:01 +0800 |
---|---|---|
committer | chai <chaifix@163.com> | 2021-10-17 23:05:01 +0800 |
commit | 7c8c68d79343d04be382334c15a73d079450857c (patch) | |
tree | 9aaacc042f0b7eeb4123c07dcc5f49c14fd8026c /Runtime/LuaBind/LuaBindMemberRef.h | |
parent | 6e73ca6ada8a41692809dae5db89c8db0675ce1e (diff) |
*misc
Diffstat (limited to 'Runtime/LuaBind/LuaBindMemberRef.h')
-rw-r--r-- | Runtime/LuaBind/LuaBindMemberRef.h | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/Runtime/LuaBind/LuaBindMemberRef.h b/Runtime/LuaBind/LuaBindMemberRef.h new file mode 100644 index 0000000..045d6ef --- /dev/null +++ b/Runtime/LuaBind/LuaBindMemberRef.h @@ -0,0 +1,27 @@ +#ifndef __LUA_BIND_MEMBER_REF_H__ +#define __LUA_BIND_MEMBER_REF_H__ + +#include "LuaBindConfig.h" + +namespace LuaBind +{ + + // + // 实例的ref table保存的member ref。由luax class做具体的管理。实例的ref table是强引用,用来管理里面member的生命周期。 + // 用来在lua和native之间进行数据沟通。 + // + class MemberRef + { + public: + MemberRef(); + ~MemberRef(); + + inline operator bool() { return refID != LUA_NOREF; }; + + int refID; + + }; + +} + +#endif
\ No newline at end of file |