Question: Question 2 Create a program for Book record keeping below: (a) Create a class called Book to represent a book. A Book should include four

 Question 2 Create a program for Book record keeping below: (a)

Question 2 Create a program for Book record keeping below: (a) Create a class called Book to represent a book. A Book should include four pieces of private information as instance variables-a book name, an ISBN number, an author name and a publisher. (4 marks) (b) Write the constructor that initializes the four instance variables. (6 marks) (c) Provide a mutator method and accessor method (query method) for each instance variable. (8 marks) (d) Provide a method named getBookInfol) that returns the description of the book as a String (the description should include all the information about the book). (2 marks) (e) Write a test application class named class BookTest (). Then, declare and create TWO (2) object for two elements in the class Book (). Display all the information for both object

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 Databases Questions!