-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathBankingProject.cpp
More file actions
39 lines (32 loc) · 933 Bytes
/
Copy pathBankingProject.cpp
File metadata and controls
39 lines (32 loc) · 933 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
//============================================================================
// Name : BankingProject.cpp
// Author :
// Version :
// Copyright : Your copyright notice
// Description : Hello World in C++, Ansi-style
//============================================================================
#include <iostream>
#include "InternalAccount.h"
#include "Person.h"
#include "Admin.h"
#include "Client.h"
#include "ExternalAccount.h"
#include "Bank.h"
#include "AccountAccessor.h"
using namespace std;
int main() {
Person *person;
ExternalAccount account;
AccountAccessor a;
InternalAccount temp[2];
account.setAccountNumber(-1);
person = a.login(person, account);
account.getInternalAccounts(temp[0],temp[1]);
if(person->getUserName().compare("admin") !=0){
(static_cast<Client*>(person))->setHeldAccount(temp[0],temp[1]);
}
person->printOptions();
free (person);
person = NULL;
return 0;
}