Youre asked to implement an order processing program to


Program Specifications

You're asked to implement an Order Processing program to keep track of orders for customers and process them if needed. The program will read a text file containing customer orders in arbitrary order and then process them Class Design

Re-use Item->InventoryItem->Product->eProduct and DairyProduct class hierarchy from lab 3
Address: (street number, street name, zipcode, state): provide constructors/destructor/member functions as required in previous labs
Order: this is a template class representing an Order of . That can be an eProduct object, a DairyProduct object, an OnlineProduct object, or a pointer to an Item object. All constructors/destructor/member functions must be defined outside of class declaration

Data: OrderId (string), OrderDate (long): number of seconds after 1/1/1970, item ()

Constructors
default: initialize string to "", long to 0

non-default constructor: take a string, a long, and

Destructor: output order information

Functions: GetOrderId/SetOrderId/GetItem/SetItem/GetOrderDate/SetOrderDate and other functions if needed

Operator overloading: overload == operator so that it returns true if 2 orders are the same. Two orders are the same if they have the same

OrderId and the same

OrderProcessingSystem

Data: store name (string), store ID (string), pointer to Address, a map of customer orders (key: customer ID(string), value: a deque containing Order objects)

Constructors

default constructor: initialize strings to "", pointers to NULL

non-default constructor: take 2 string parameters for store name and store ID, an integer for street number, a string for street name, an integer for zipcode, and a string for state. It will dynamically allocate an Address object as well as initialize other members as appropriate
Destructor: de-allocate Address pointer and the Item * in each Order in each deque container in the map. You will need to iterate thru the map. Each entry in the map contains customer orders (deque of Order ) for a particular customer. Then iterate thru each deque container and delete all Item pointers in each deque.

Overload assignment operator operator= (you may ignore the map)

Member functions:
Init: read a text file to load customer orders
Menu: display a menu (invoked by start function below)
MENU
Show All Orders
Find Order by Customer ID
Process Order
Quit
Please enter an option (4 to quit): 1

Start: use a do while loop to display a menu and invoke ShowAllOrders, FindOrder, ProcessOrder per user option
ShowAllOrders: display all orders by customer ID
FindOrders: input a customer ID and display all orders by that customer
ProcessOrder: input a customer ID and an order ID then process (remove it from the deque) the order for that customer

Request for Solution File

Ask an Expert for Answer!!
Basic Computer Science: Youre asked to implement an order processing program to
Reference No:- TGS01030461

Expected delivery within 24 Hours