blob: 8fe781bd9166e5655825da00f3420d09b2972cf7 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
#ifndef __LUA_VM_H
#define __LUA_VM_H
#include "LuaGlueExportable.hpp"
#include "lua.hpp"
#include <string>
class LuaVM
{
public:
LUAGLUE_DLL_VISIBLE LuaVM( );
LUAGLUE_DLL_VISIBLE ~LuaVM( );
LUAGLUE_DLL_VISIBLE void loadSource( const char *sourceFilename );
void executeMain( );
void executeFunction( const std::string &f );
LUAGLUE_DLL_VISIBLE void dumpState( );
LUAGLUE_DLL_VISIBLE void fullGarbageCollect( );
LUAGLUE_DLL_VISIBLE lua_State *handle( );
private:
void initialize( );
private:
lua_State *m_lua;
std::string m_sourceFilename;
};
#endif
|