-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathBookManager.h
36 lines (33 loc) · 1.21 KB
/
BookManager.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
#pragma once
#include "BookInfo.h"
#include <string>
class BookManager{
private:
//Values to adjust # of characters in elements for in-terminal book info display:
int maxIdDisplayLength = 6;
int maxTitleDisplayLength = 40;
int maxAuthorDisplayLength = 15;
void appendBookToDatabase(std::string, std::string, std::string, std::string, std::string, int);
void displayAddBookUI();
void displayEditBookUI();
void processBookChanges(std::string,int ,std::string);
void processBookChanges(std::string, int, int);
int convertStringToInt(std::string);
bool displayChanges(BookInfo*&, BookInfo*&);
void allocatePreparedEditStatement();
void allocatePreparedRetrieveStatement();
void editBookMenuUI(BookInfo*&);
void manageEditMenuSelection(int, BookInfo*&);
void bookDeletionProcess(int, BookInfo*);
void allocatePreparedDeletionStatement();
bool isBookIDValid;
void retrieveBookByID(int, BookInfo*&);
public:
bool checkDate(std::string);
void addBookProcess();
void editBookProcess();
bool retrieveBookByID(BookInfo*&);
void displayBookListFullInfo(BookInfo*);
void displayBookDataListFormat(BookInfo*);
void displayBookListHeader();
};