RequestManager.h 894 Bytes
#ifndef REQUESTMANAGER_H
#define REQUESTMANAGER_H

#include <string>

#include "../Application/Application.h"
#include "RequestAbstract.h"
#include "RequestLoader.h"
#include "ResultWriter.h"

using namespace TREPS::Application;

namespace TREPS
{
	namespace RequestManager
	{
		class RequestManagerClass
		{
			public:
				RequestManagerClass(void);

				~RequestManagerClass(void);

				//init request
				bool init(const char *file_path);
				
				//run request
				bool run(void);

				//write request result
				string writeResult(bool runRes);

				//get result file name
				string getResultFileName(void);

				//get cache result
				string getCacheResult(void);
				
			private:
				ApplicationClass *app;

				RequestLoaderClass *loader;
				
				ResultWriterClass *writer;
				
				RequestAbstractClass *request;
		};
	}
}	

#endif