diff options
Diffstat (limited to 'Sluift/LuaElementConvertors.h')
-rw-r--r-- | Sluift/LuaElementConvertors.h | 66 |
1 files changed, 33 insertions, 33 deletions
diff --git a/Sluift/LuaElementConvertors.h b/Sluift/LuaElementConvertors.h index 1e9dc97..6b3d343 100644 --- a/Sluift/LuaElementConvertors.h +++ b/Sluift/LuaElementConvertors.h @@ -16,37 +16,37 @@ struct lua_State; namespace Swift { - class LuaElementConvertor; - class Element; - - class LuaElementConvertors { - public: - LuaElementConvertors(); - virtual ~LuaElementConvertors(); - - boost::shared_ptr<Element> convertFromLua(lua_State*, int index); - int convertToLua(lua_State*, boost::shared_ptr<Element>); - - /** - * Adds a toplevel type+data table with the given type. - */ - boost::shared_ptr<Element> convertFromLuaUntyped(lua_State*, int index, const std::string& type); - - /** - * Strips the toplevel type+data table, and only return the - * data. - */ - int convertToLuaUntyped(lua_State*, boost::shared_ptr<Element>); - - const std::vector< boost::shared_ptr<LuaElementConvertor> >& getConvertors() const { - return convertors; - } - - private: - boost::optional<std::string> doConvertToLuaUntyped(lua_State*, boost::shared_ptr<Element>); - void registerConvertors(); - - private: - std::vector< boost::shared_ptr<LuaElementConvertor> > convertors; - }; + class LuaElementConvertor; + class Element; + + class LuaElementConvertors { + public: + LuaElementConvertors(); + virtual ~LuaElementConvertors(); + + boost::shared_ptr<Element> convertFromLua(lua_State*, int index); + int convertToLua(lua_State*, boost::shared_ptr<Element>); + + /** + * Adds a toplevel type+data table with the given type. + */ + boost::shared_ptr<Element> convertFromLuaUntyped(lua_State*, int index, const std::string& type); + + /** + * Strips the toplevel type+data table, and only return the + * data. + */ + int convertToLuaUntyped(lua_State*, boost::shared_ptr<Element>); + + const std::vector< boost::shared_ptr<LuaElementConvertor> >& getConvertors() const { + return convertors; + } + + private: + boost::optional<std::string> doConvertToLuaUntyped(lua_State*, boost::shared_ptr<Element>); + void registerConvertors(); + + private: + std::vector< boost::shared_ptr<LuaElementConvertor> > convertors; + }; } |