File: CompileState.h

package info (click to toggle)
fastdep 0.16-7
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 596 kB
  • ctags: 323
  • sloc: cpp: 2,144; ansic: 814; sh: 208; makefile: 124
file content (38 lines) | stat: -rw-r--r-- 885 bytes parent folder | download | duplicates (5)
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
#ifndef COMPILESTATE_H_
#define COMPILESTATE_H_

#include <string>
#include <vector>

class CompileState
{
	public:
		CompileState(const std::string& aBase);
		CompileState(const CompileState& anOther);
		virtual ~CompileState();

		CompileState& operator=(const CompileState& anOther);

		void addDependencies(const std::string& aString);
		std::string getDependenciesLine() const;

		void define(const std::string& aString, const std::string& aContent);
		void undef(const std::string& aString);
		bool isDefined(const std::string& aString) const;
		std::string getContent(const std::string& aName) const;

		void dump() const;

		void mergeDeps(std::vector<std::string>& aDepLine);
		void inDebugMode();

	private:
		std::vector<std::string> Dependencies;
		std::string Basedir;
		std::vector<std::string> Defines;
		std::vector<std::string> Contents;
		bool	DebugMode;
};

#endif