Write My Paper Button

WhatsApp Widget

My academic blog

Secure the furure

My academic blog

Secure the furure

The driver class should be Singleton and should be able to track all users, products and bids that are currently active and the ones that have been completed. This class will control the application interface and the flow of the program. This class will also write the new bids, that have bee

Assignment Task

Objectives

  • Develop familiarity with the concept of “static
  • Implement and use the Factory design pattern
  • Design and implement a multi-object program, dealing with the intricacies of objects communicating with one another

Design Document 

Your document should include clear indications of your class design and the interaction between the classes. You do not need to follow formal diagramming language, but your diagram needs to be legible and communicate the information described above.

Program Flow

1. Initialize application from the csv files.

2. First, the user should choose a role, that of a Buyer or Seller

3. If Seller, they should be able to:

a. post a product for sale – should also have the option to view prices of similar products that were historically sold.

b. read and respond to messages from buyers,

c. check their account balance,

d. update their user information,

e. get an overview of their products that have been sold or are yet to be sold f. open/close bids on their products

4. If Buyer, they should be able to:

a. view products for sale,

b. place a bid on

a product of their choice

c. read, respond, send to new messages from sellers,

d. check their account balance,

e. update their user information,

f. get an overview of the bids they have placed

g. view the history of products they have bought

5. The driver class should be Singleton and should be able to track all users, products and bids that are currently active and the ones that have been completed. This class will control the application interface and the flow of the program. This class will also write the new bids, that have been closed, to the product/bid information csv as these will be considered historical bids.

Bidding

Each product that is placed for sale will be open to accepting bids until the seller closes the bid. The buyers may place a bid only products are active for bidding. A buyer should not be able to place a bid that exceeds their account balance. You may assume they have a fictional balance amount in their account at the start of the run. A buyer may place a bid on more than one product. Once a bid has been closed, the buyer with the highest bid will own the product. The buyers should be notified through messages if they won or lost the bid. Once the selling process is complete, the account balances of the buyer and the seller are updated. At the time of sale, if the buyer refuses to buy the product or if the account balance of the buyer is less than the bid, the sale to that buyer is cancelled and the bid is won by the buyer with next best bid. The product is then taken off the market.

Messaging between Buyer and Seller

A buyer may message a seller if they win the bid for the seller’s product. Similarly, a seller may also message only a buyer who has won a bid for their product. Both parties can share messages. The users should be able to respond to the messages. You may use any underlying data structure to do this. Using one that is time and storage efficient, will grant you extra credit points.

Products

You are required to implement at least 5 concrete product category classes each having at least one level of inheritance. All products should have a base price at which the bid will start. The seller must indicate the quality of the product when posting one for sale. The quality can be one of these: New, Used-VeryGood, Used-good, Used-okay. Depending on the product, you have the freedom to decide additional behavior and data points for the classes. Plan to have detailed classes. Well-designed and detailed inheritance design will contribute to the extra credit. Here is a code snippet that may help understand the product inheritance expectation:

Getting Started

(Deliverable 2): Reminder: You may find incorporating std::map into your program, to track bids, very useful

1. Use factory design pattern when seller is adding a product for sale. a. You are welcome to use other design patterns as applicable in different parts of the program.

2. Write an outline for the user and product classes. private: add more fields as applicable }; class Product class Product1: public Product class Product public Product

3. Write a main.cpp that allows you to instantiate the driver class and build a map of dummy bids

 

The driver class should be Singleton and should be able to track all users, products and bids that are currently active and the ones that have been completed. This class will control the application interface and the flow of the program. This class will also write the new bids, that have bee
Scroll to top

Get Homework Help Online From Expert Tutors

X
WeCreativez WhatsApp Support
Our customer support team is here to answer your questions. Ask us anything!
👋 Hi, how can I help?