summaryrefslogtreecommitdiffstats
path: root/source/LuaScript.h
blob: 99ccb3d497da0584543d308f590d220c2431ed3d (plain) (blame)
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
33
34
35
36
37
38
39
40
41
42
43
44
45

// LuaScript.h

// Declares the cLuaScript class that loads a Lua script file to produce a web template out of it





#pragma once

#include "LuaState.h"





// fwd:
class cWebAdmin;
struct HTTPTemplateRequest;





class cLuaScript
{
public:
	cLuaScript(void);

	/// Prepares a Lua state
	void Initialize();

	/// Load a Lua script on the given path
	bool LoadFile(const char * a_FilePath);

	bool CallShowPage(cWebAdmin & a_WebAdmin, HTTPTemplateRequest & a_Request, AString & a_ReturnedString);

protected:
	cLuaState m_LuaState;
} ;