Changeset 5774 for code/trunk/src/libraries/core/LuaState.h
- Timestamp:
- Sep 23, 2009, 11:31:02 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk/src/libraries/core/LuaState.h
r5738 r5774 45 45 namespace orxonox 46 46 { 47 //! Stores basic information about a File 48 struct ResourceInfo 49 { 50 //! The file's fully qualified name 51 std::string filename; 52 //! Path name; separated by '/' and ending with '/' 53 std::string path; 54 //! Base filename 55 std::string basename; 56 }; 57 47 58 /** 48 59 @brief … … 56 67 ~LuaState(); 57 68 58 void doFile(const std::string& filename, const std::string& resourceGroup = "General",bool bSearchOtherPaths = true); // tolua_export69 void doFile(const std::string& filename, bool bSearchOtherPaths = true); // tolua_export 59 70 void doString(const std::string& code, shared_ptr<ResourceInfo> sourceFileInfo = shared_ptr<ResourceInfo>()); 60 71 61 void includeFile(const std::string& filename, const std::string& resourceGroup = "General",bool bSearchOtherPaths = true); // tolua_export72 void includeFile(const std::string& filename, bool bSearchOtherPaths = true); // tolua_export 62 73 void includeString(const std::string& code, shared_ptr<ResourceInfo> sourceFileInfo = shared_ptr<ResourceInfo>()); 63 74 64 75 void luaPrint(const std::string& str); // tolua_export 65 76 void luaLog(unsigned int level, const std::string& message); // tolua_export 66 bool fileExists(const std::string& filename, const std::string& resourceGroup = "General",bool bSearchOtherPaths = true); // tolua_export77 bool fileExists(const std::string& filename, bool bSearchOtherPaths = true); // tolua_export 67 78 68 79 const std::stringstream& getOutput() const { return output_; } … … 78 89 79 90 private: 80 shared_ptr<ResourceInfo> getFileInfo(const std::string& filename, const std::string& resourceGroup, bool bSearchOtherPaths); 91 shared_ptr<ResourceInfo> getFileInfo(const std::string& filename, bool bSearchOtherPaths); 92 shared_ptr<ResourceInfo> getFileInfo(const std::string& filename); 93 std::string loadFile(const std::string& filename); 81 94 82 95 #if LUA_VERSION_NUM != 501
Note: See TracChangeset
for help on using the changeset viewer.