Programming, Utility Coffeeshop Code in C++ Worksheet
Description
I need to get rid of Clementine.h, but still be able to call runMenuSystems in Loan.cpp and Retirement.cpp(Do not change Loan.h or Retirement.h). Also I need to add Register.cpp and Register.h.
You will create a new class called Register with associated header and implementation files. The purpose of
Register is to prompt the user for the name of a text file that contains a list of transactions that include date,
type, location, and the amount credited/debited.
o Register is required to have the following public methods:
§ Default constructor Register();
§ string getFileName();
Prompt the user for the name of the file and returns that as a string.
§ void setFileName (string);
Set the class’ private variable to a filename sent into the function.
§ bool processTransaction();
Serves as the driver for Register and is used to call getFileName, setFileName,
readFromFile, and printFile. Returns true if it completes successfully, false
otherwise.
§ bool readFromFile();
The purpose of this function is to use the internal private filename to read through the
input file and populate the classes’ vectors to store information. You will not know how
many line items there are. This function returns back true if the file is opened and read
successfully, false otherwise.
§ void printFile();
Will print out the transactions in a neatly formatted table.
o Register is required to use an enumerated type called Transactions that contains, in this order, types
for RESTAURANT, MERCHANDISE, UTILITY, COFFEESHOP, AUTOMOTIVE, DEPOSIT,
OTHER.
I have attached sample output and code i have already written
Need help with a similar or different Task?
We have the best writers to help you. Hire Writer Now