Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Create a class named Movie that can be used with your video rental business. The Movie class should track the Motion Picture Assoiation of America

Create a class named Movie that can be used with your video rental business. The Movie class should track the Motion Picture Assoiation of America (MPAA) rating (e.g., Rated G, PG-13, R), ID Number, and movie title with appropriate accessor and mutator methods. Also create an equals() method that overridesObject's equals() method, where two movies are equal if their ID number is identical. Next, create three additional classes named Action, Comedy, and Drama that are derived from Movie. Finally, create and overridden method named calcLateFees that takes as input the number of days a movie is late and returns the late fee for that movie. The defualt late fee is $2/day. Action movies have a late fee of $3/day, comedies are $2.50/day, and dramas are $2/day. Test your classes from a main method.

In addition to the requirements listed in the book, you are expected to include the following:

* All appropriate accessor and mutator methods (getters and setters).

* An 'equals' method (must conform to the Person example and the Object class).

* A 'toString' method

* The default and overloaded constructors

* A 'copy' constructor

* A 'clone' method

* A 'finalize' method

* A 'dispose' method

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Databases DeMYSTiFieD

Authors: Andy Oppel

2nd Edition

0071747990, 978-0071747998

More Books

Students also viewed these Databases questions