aboutsummaryrefslogtreecommitdiff
path: root/src/perform.h
blob: ea8d5e310883585902cf93de3d78a3b923d1b401 (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
44
45
46
47
48
49
50
51
52
53
54
#ifndef PERFORM_H
#define PERFORM_H

#include <stdint.h>
#include <list>
#include <string>
#include <map>

typedef std::map<std::string,std::string> VarMap;

class Build;

class Perform
{
public:
	Perform();
	virtual ~Perform();

	void addParam( const char *sParam );
	virtual Perform *duplicate( Build &bld, const std::string &cont, VarMap *mExtra ) = 0;
	virtual void execute( Build &bld ) = 0;
	void copyData( Perform *pSrc, Build &bld, const std::string &cont, VarMap *mExtra );
	std::string getTarget()
	{
		return sTarget;
	}
	void setTarget( std::string sTarget )
	{
		this->sTarget = sTarget;
	}

	std::list<class Function *> &getReqFuncs()
	{
		return lReqFuncs;
	}

	void setRule( const std::string &sRule )
	{
		this->sRule = sRule;
	}

	std::string &getRule()
	{
		return sRule;
	}

protected:
	std::list<std::string> lParam;
	std::string sTarget;
	std::string sRule;
	std::list<class Function *> lReqFuncs;
};

#endif