Question: Java Programing Programming 1. Consider publications of books and magazines. Write a class called Publication, Publication have attributes title, price and year. Include Book and

Java Programing  Java Programing Programming 1. Consider publications of books and magazines. Write
a class called Publication, Publication have attributes title, price and year. Include

Programming 1. Consider publications of books and magazines. Write a class called Publication, Publication have attributes title, price and year. Include Book and Magazine et subelasses of Publication. Let an author be an attribute of Book while Magazine has periodical information such as monthly, biweekly, or weekly. Book and Magazine classes should have Publisher class to use. Let the attributes of Publisher be compan name and location. Book has Textbook and Reference as subclasses. Textbook has subject and title as its attributes. Reference has its type such as url address and title as its attributes. Use appropriate modifiers like public, private or protected. Include a separate driver class called AppDriver. a. Draw a UML with has-a and is-a hierarchies among the classes clearly marked. b. Write all the above classes with attributes and methods. Use appropriate modifiers for all the attributes and methods. c. Include short explanation of each method by identifying input parameters and return types if applicable

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!