-
Notifications
You must be signed in to change notification settings - Fork 0
/
program.cpp
42 lines (34 loc) · 853 Bytes
/
program.cpp
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
/*
program.cpp
Author: M00851681
Created: 11/12/23
Updated: 11/1/24
*/
#include "main.h"
int main(int argc, char* argv[])
{
std::cout << std::endl << "Library BooK System" << std::endl
<< "Coursework1, M00851681" << std::endl
<< std::endl;
std::string FILENAME;
std::vector<Book*> booksArray;
std::vector<Member*> membersArray;
const int ARGUMENTSCOUNT = argc;
std::cout << "test";
if (!checkNumberOfArguments(ARGUMENTSCOUNT, argv, FILENAME))
{
return 1;
};
if (checkFileExists(FILENAME))
{
readFile(FILENAME, booksArray);
Librarian staffId;
mainMenu(&staffId, booksArray, membersArray);
}
else
{
std::cout << "No library book file was found" << std::endl;
return 1;
}
return 0;
}