-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathctemplate.h
51 lines (32 loc) · 1.05 KB
/
ctemplate.h
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
#pragma once
#include <string>
#include "templateProj.h"
class cTemplate : public ITemplate {
public:
cTemplate(char *t)
: ITemplate(t) {}
cTemplate(char *t, char *c)
: ITemplate(t, c) {}
~cTemplate() {}
private:
void genMakefile(std::string &fmakefile, const std::string projname);
void genHeader(std::string &fheader);
void genFunction(std::string &ffunc, const std::string funcname);
void genMain(std::string &fmain, const std::string callfunc);
void Process();
};
class cppTemplate : public ITemplate {
public:
cppTemplate(char *t)
: ITemplate(t) {}
cppTemplate(char *t, char *c)
: ITemplate(t, c) {}
~cppTemplate() {}
private:
void genMakefile(std::string &fmakefile, const std::string projname);
void genHeader(std::string &fheader);
void genClass(std::string &fclass, const std::string classname);
void genFunction(std::string &ffunc, const std::string funcname);
void genMain(std::string &fmain, const std::string callclass);
void Process();
};