OpenMW
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
scriptmanager.hpp
Go to the documentation of this file.
1 #ifndef GAME_MWBASE_SCRIPTMANAGER_H
2 #define GAME_MWBASE_SCRIPTMANAGER_H
3 
4 #include <string>
5 
6 namespace Interpreter
7 {
8  class Context;
9 }
10 
11 namespace Compiler
12 {
13  class Locals;
14 }
15 
16 namespace MWScript
17 {
18  class GlobalScripts;
19 }
20 
21 namespace MWBase
22 {
25  {
28 
31 
32  public:
33 
35 
36  virtual ~ScriptManager() {}
37 
38  virtual void run (const std::string& name, Interpreter::Context& interpreterContext) = 0;
40 
41  virtual bool compile (const std::string& name) = 0;
44 
45  virtual std::pair<int, int> compileAll() = 0;
48 
49  virtual const Compiler::Locals& getLocals (const std::string& name) = 0;
51 
53  };
54 }
55 
56 #endif
virtual const Compiler::Locals & getLocals(const std::string &name)=0
Return locals for script name.
ScriptManager & operator=(const ScriptManager &)
not implemented
Definition: globalscripts.hpp:38
ScriptManager()
Definition: scriptmanager.hpp:34
virtual std::pair< int, int > compileAll()=0
Definition: interpreter.hpp:16
Definition: context.hpp:9
virtual MWScript::GlobalScripts & getGlobalScripts()=0
Interface for script manager (implemented in MWScript)
Definition: scriptmanager.hpp:24
virtual void run(const std::string &name, Interpreter::Context &interpreterContext)=0
Run the script with the given name (compile first, if not compiled yet)
virtual ~ScriptManager()
Definition: scriptmanager.hpp:36
virtual bool compile(const std::string &name)=0
Local variable declarations.
Definition: locals.hpp:12
const char * name
Definition: crashcatcher.cpp:59