-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.cpp
More file actions
62 lines (49 loc) · 929 Bytes
/
Copy pathmain.cpp
File metadata and controls
62 lines (49 loc) · 929 Bytes
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
55
56
57
58
59
60
61
62
#include<iostream>
#include"FrontController/FrontController.h"
#include<string>
using namespace std;
int main()
{
displayFloristSign();
Dispatcher dispatcher;
FrontController frontController;
frontController.set(&dispatcher);
const string noTestPattern[] = { "frontController", "RAII", "singleton"};
int user = 2;//2¸öÖ®ºóÊÇuser
int orders = 9; //
int sells = 14;
int employees = 20;
for (int i = 0; i < 23; i++)
{
if(i==0){
material();
}
else if(i==user){
purchase();
}
else if(i==orders){
order();
}
else if(i==sells){
sell();
}
else if(i==employees){
employee();
}
bool continueFlag = false;
for (auto str : noTestPattern) {
if (designPatterns[i] == str) {
continueFlag = true;
break;
}
}
if (continueFlag) {
continue;
}
frontController.dispatchRequest(designPatterns[i]);
system("pause");
cout << endl;
}
testAll();
return 0;
}