????????????Lua??C/C++??????????????????????????????LuaBridge???Lua??C/C++?????????????????????????Reference Manual?????????????飬???????????????????????github???
????LuaBridge????????
???????????????????.cpp????????MakeFile????????????#include???ɡ?
??????????????????????????????
??????Lua?????????????????????type-safe????
????Automatic function parameter type binding.
????Easy access to Lua objects like tables and functions.
????LuaBridge??API?????C++????????template metaprogramming?????????????Щ?????????????Lua API??????????????Lua????????C++?????е????????????????C++?????Lua???????????number??string??table??????????Lua??????????LuaBridge?е?LuaRef???????????????
????LuaBridge??????
????????LuaBridge?????????????????????????????????????????C++??????????????á????LuaBridge??????????????????????????OOLua??https://code.google.com/p/oolua/?????Ч???????????????????LuaBind??http://www.rasterbar.com/products/luabind.html????????????檔LuaBridge??????????????
????????????
?????????8???????????????????
??????????????????????????Overloaded functions?? methods?? or constructors??
??????????????????????????????????
????????????STL?????????Table
??????Lua?м??C++??Inheriting Lua classes from C++ classes????
????Passing nil to a C++ function that expects a pointer or reference
????Standard containers like std::shared_ptr
??????Lua????C++
?????????Lua?????C++?е???????????LuaBridge????κ????????????????????LuaBridge????????????????????????
????Namespaces  ???Lua table????????????????
????Data  ??????????????????????????????
????Functions  ????????????????????????
????CFunctions  A regular function?? member function?? or static member function that uses the lua_CFunction calling convention
????Properties  Global properties?? property members?? and static property members. These appear like data to Lua??but are implemented in C++ using functions to get and set the values.
????Data??Properties?????????????????read-only?????????const????Щ??????????C++??????????????Lua?????????
????Namespaces
????LuaBridge????????????????namespace?У?namespace???lua???????????????????table??????????namespace????C++?е?namespace??C++??namespace?????????????LuaBridge??namespace???Lua???????????????????????????logical grouping tool??????????Lua????????????global namespace??????????C++?У??????????
????<span style="font-size:14px;">getGlobalNamespace (L);</span>
???????????????????????????table???????????????????磺
????<span style="font-size:14px;">     getGlobalNamespace (L)
????.beginNamespace ("test");</span>
???????????????Lua??_G?д?????????"test"??table?????????table???????LuaBridge???????????????????????????????__test????Ч????????????????????LuaBridge?????????????????????????????
<span style="font-size:14px;">    getGlobalNamespace (L)
.beginNamespace ("test")
.beginNamespace ("detail")
.endNamespace ()
.beginNamespace ("utility")
.endNamespace ()
.endNamespace ();</span>