-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathVoter.cpp
More file actions
31 lines (22 loc) · 823 Bytes
/
Voter.cpp
File metadata and controls
31 lines (22 loc) · 823 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
#include "Voter.h"
using namespace std;
Voter::Voter(std::string core_arg_host_url, std::string core_arg_owner_vsID, std::string core_arg_class_id, std::string core_arg_object_id)
: Core(core_arg_host_url, core_arg_owner_vsID, core_arg_class_id, core_arg_object_id)
{
cout << "Voter Constructor" << endl;
}
Voter::Voter(std::string core_arg_host_url, std::string core_arg_owner_vsID, std::string core_arg_class_id, std::string core_arg_object_id, std::string name, int voterID)
: Core(core_arg_host_url, core_arg_owner_vsID, core_arg_class_id, core_arg_object_id)
{
this->name = name;
this->voterId = voterID;
}
int Voter::getVoterId(){
return this->voterId;
}
std::string Voter::getName(){
return this->name;
}
std::string Voter::getVoterInfo(){
return to_string(this->getVoterId()) + this->getName();
}