blob: 8b82342ad1ecb24c19d19856d868ea78f8be4f07 (
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
33
34
35
36
37
|
/*
* Context.h
*
* Created on: Dec 7, 2012
* Author: attero
*/
#ifndef CONTEXT_MANAGER_H_
#define CONTEXT_MANAGER_H_
#include <map>
#include <string>
#include <iostream>
#include <stack>
#include "Context.h"
class ContextManager {
public:
ContextManager();
std::stack<Context *> stack;
std::map<std::string, Context *> contexts;
Context * create_new_context();
void destroy_context(std::string name);
Context * get_context(std::string name);
Context * context(std::string name);
Context * get_top();
SenchaObject execute_function(std::string name, std::vector<ASTExpression *> arguments);
void pop_context();
unsigned int index;
virtual ~ContextManager();
};
#endif /* CONTEXT_MANAGER_H_ */
|