-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsim_task.h
More file actions
63 lines (48 loc) · 1.47 KB
/
sim_task.h
File metadata and controls
63 lines (48 loc) · 1.47 KB
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
63
#ifndef SIM_TASK_H
#define SIM_TASK_H
#include <string>
#include <utility>
#include "task.h"
#include <string>
#include <vector>
#include <mutex>
#include "global.h"
/** Task that prints a message to cout. */
class SimTask : public Task
{
public:
SimTask(std::pair<std::pair<int, std::string>, std::pair<int, std::string>> player_hand, std::pair<int, std::string> dealer_hand, std::string choice, const int& count)
: player_hand_(std::move(player_hand)), dealer_hand_(std::move(dealer_hand)), choice_(std::move(choice)), count_(count)
{
}
void run();
private:
const std::pair<std::pair<int, std::string>, std::pair<int, std::string>> player_hand_;
const std::pair<int, std::string> dealer_hand_;
const std::string choice_;
const int count_;
};
class SimTaskNonPar : public Task
{
public:
SimTaskNonPar(const int& DA, std::pair<std::pair<int, std::string>, std::pair<int, std::string>> player_hand, std::pair<int, std::string> dealer_hand, std::string choice)
: deckAmount_(DA),player_hand_(std::move(player_hand)), dealer_hand_(std::move(dealer_hand)), choice_(std::move(choice))
{
}
void run();
private:
const int deckAmount_;
const std::pair<std::pair<int, std::string>, std::pair<int, std::string>> player_hand_;
const std::pair<int, std::string> dealer_hand_;
const std::string choice_;
};
class StartTask : public Task
{
public:
StartTask()
{
}
void run();
private:
};
#endif