Question: Examine the provided Bookstore class. Currently, this project is missing the Member and PremiumMember classes Your first task will be to add those classes. Use

Examine the provided Bookstore class. Currently, this project is missing the Member and PremiumMember classes
Your first task will be to add those classes. Use the following description to write the missing classes.
Member extends an abstract class Person
PremiumMember extends Member
Person has attributes:name (String)
Member has attributes:name (String),numberPurchases(int)
PremiumMember has attributes:name (String),numberPurchases(int),hasPaidDues(boolean)
There should be getters and setters for each attribute, and the necessary constructors for those attributes.
Instead of having a setter forhasPaidDues, PremiumMember should have one a method called payDues(), that ifhasPaidDues is false, switches the value to true.
Next, navigate to the Bookstore class. Notice that there are two types of ArrayList, one for each type of Member. Change this so that both member types use the same ArrayList.
Finally, scroll to line 61. There is a partial method called registerNewMember() that needs to be finished. Complete the method so that a new Member can enter their name and be added to the list of members. You shouldn't need to edit any other part of the main method. After a member is added, you should be able to confirm they were added correctly by using theCheck Member Status option in the menu
Examine the provided Bookstore class. Currently,

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!