Question: JUSThelp me with the display part, thank you C++question: class InventoryItem (minimum implementation specified below) - This is the base class. Protected member data: item

JUSThelp me with the display part, thank you

C++question:

class InventoryItem (minimum implementation specified below) - This is the base class.

  • Protected member data: item id (integer) and restocking (bool).
  • Public static data:
    • const integer (item id): initialize to 9999.
    • const bool (restocking): initialize to false.
  • Constructors
    • Default constructor: initialize item id and restocking using the default static data with member initializer syntax.
    • Non-default constructor: take 2 parameters.
  • Destructor: output "InventoryItem with restocking destroyed ..."
  • Public member functions:
    • mutator/accessor for restocking, item id.
    • Display: to show InventoryItem item id and restocking (true/false). item id must be displayed as a 4-digit integer with leading 0s if

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!