summaryrefslogtreecommitdiff
path: root/project2/console/consoleAppEngine.h
blob: b75d9b1e3d556ec9d3fc337387468c181f759353 (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
38
39
40
41
42
43
#ifndef CONSOLEAPPENGINE_H
#define CONSOLEAPPENGINE_H

#include "task.h"
#include "presenter.h"
#include "commonObjects.h"
#include "view.h"
#include "execContext.h"
#include <vector>
#include <boost/tuple/tuple.hpp>

class ConsoleApplicationEngine : public ExecContext {
	public:
		ConsoleApplicationEngine();
		virtual ~ConsoleApplicationEngine();

		void process();
		VariableType getParameter(const VariableType&) const;
		SessionPtr getSession() const;

		INITOPTIONS;

	private:
		void process(ScriptReaderPtr);

		typedef boost::tuple<Glib::ustring, Glib::ustring> ToDo;
		typedef std::vector<ToDo> ToDoList;
		typedef std::map<Glib::ustring, const Glib::ustring> ConsolePlatforms;
		typedef std::map<std::string, std::string> Parameters;

		friend class CommandLineArguments;
		mutable ConsolePlatforms conplat;
		SessionPtr runtime;
		MultiRowSetPresenterPtr presenter;

		static ToDoList todolist;
		static Parameters parameters;
	public:
		static Glib::ustring reqPlatform;
};

#endif