-
Notifications
You must be signed in to change notification settings - Fork 1
/
Driver.h
59 lines (40 loc) · 1.39 KB
/
Driver.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
52
53
54
55
56
57
58
59
//
// Created by Levi on 12/10/2018.
//
#ifndef PHEONIXCOINCURRENTBRANCH_DRIVER_H
#define PHEONIXCOINCURRENTBRANCH_DRIVER_H
#include <string>
#include "Block.h"
#include "BlockChain.h"
using namespace std;
class Driver {
private:
string configName;
BlockChain primaryChain;
Block unminedBlock;
public:
//constructors
Driver();
Driver(const string &configName, const string &resultFileName, const Block &unminedBlock, const BlockChain &primaryChain);
//primary Method
const string drive();
//worker methods
const string newUser();
const string newTrans();
const string mine();
//method to output objects that opperations were prefomed on
void outPut(Block &blockIn, BlockChain &blockChainIn);
//helper Methods
//This method gets the opperation to perform from the config file
const string getOpFromConfigFile();
//This opperation gets the ammount of lines in the config file
const int getLinesInConfig();
//setters and getters
const string &getConfigName() const;
void setConfigName(const string &configName);
const BlockChain &getPrimaryChain() const;
void setPrimaryChain(const BlockChain &primaryChain);
const Block &getUnminedBlock() const;
void setUnminedBlock(const Block &unminedBlock);
};
#endif //PHEONIXCOINCURRENTBRANCH_DRIVER_H