This project goal is to develop a rental media system This underneath UML diagram may help you to understand the system requirements EMediaRentalManger «MediaRentallnt» Media «Comparable» Customer Game Movie Album

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question

solve this question using java also you will need do use a file in driver class ,d1 will help you  to understand the realation between the classes, and d3 to know the function in index A

you must define a class named MediaRental that implements the MediaRentalInt interface functionality
(index A). You must define classes that support the functionality specified by the interface:
. Define a class named MediaRental. Feel free to add any instance variables you understand are needed or any private methods. Do not add any public methods (beyond the ones specified in the MediaRentalInt interface).
. The media rental system keeps track of customers and media (movies ,music albums and games). A customer
has a name, address as string , a plan and two lists. One list represent the media the customer is interested in
receiving and the second one represents the media already received (rented) by the customer. There are two
plans a customer can have: UNLIMITED and LIMITED. UNLIMITED allows a customer to receive as many media
as they want; LIMITED restricts the media to a default value of 2 (this value can be change via a media rental
class method).
A movie has a title, a number of copies available and a rating (e.g., "HR"). An album has a title, number of
copies available, an artist and the songs that are part of the album. A game has title,number of copies,and the
weight (in grams) is also stored.
. You must define and use at least four classes (not including MediaRental) as part of your design. At least two of
those classes must be in a superclass/subclass relationship (Inheritance Requirement). The other two can be
defined as you wish. Feel free to define as many classes as you want. These classes must support the
functionality of the system otherwise you will not receive any credit.
. One of your classes must define an equals method that has as parameter an Object parameter.
. The database for your system needs to be represented using two ArrayList objects. One ArrayList will represent
the customers present in the database; the second will represent the media (movies, albums , and games).
. Regarding the searchMedia method: the songs parameter represents a substring (fragment) or the full list of
songs associated with the album. If the full list is provided you can assume commas will be part of the string.
Hint: you may want to consider using the indexOf method of the String class.
7. Your program should store the results in a file between executions of the program, so
that when the program is run again it will start up with the same inventory contents as
when it last terminated.
.  free to use Collections.sort to sort your data.
. Write test driver.
. Handle expectations where it’s needed.
.Not all the details associated with the project can be fully specified in this description. The sooner you start
working on the project the sooner you will be able to address any doubts you may have.

Index A
in the second picture.(d3)

index B:
Index B:
Public Driver:
Method Detail
public void testAddingCustomers()
public void testAddingMedia()
public void testingAddingToCart()
public void testingRemovingFromCart()
public void testProcessingRequestsOne()
public void testProcessingRequestsTwo()
public void testReturnMedia()
public void testSearchMedia()

This project goal is to develop a rental media system This underneath UML diagram may help you to understand the
system requirements
EMediaRentalManger
«MediaRentallnt»
Media
«Comparable»
Customer
Game
Movie
Album
Transcribed Image Text:This project goal is to develop a rental media system This underneath UML diagram may help you to understand the system requirements EMediaRentalManger «MediaRentallnt» Media «Comparable» Customer Game Movie Album
void setLimitedPlanLimit (int value)
This set the number of media associated with the LIMITED plan.
Parameters: value -
getAl1CustomersInfo
String getAliCustomersInfo ()
Returns information about the customers in the database. The information is presented sorted by cus-
tomer name.
Returns:
getAl1MediaInfo
String getAl1MediaInfo ()
Returns information about all the media (movies, albums, and games) that are part of the database. The
information
Index A:
is presented sorted by media title.
Returns:
MediaRentallnt interface Includes:
addToCart
Method Detail
boolean addToCart (String customerName, String mediaTitle)
addCustomer
Adds the specified media title to the cart associated with a customer.
void addCustomer (String name, String address, String plan)
Adds the specified customer to the database. The address is a physical address (not e-mail). The plan
Parameters:customerName - , mediaTitle -
Returns: false if the mediaTitle is already part of the cart (it will not be added)
options available
removeFromCart
are: LIMITED and UNLIMITED. LIMITED defines a default maximum of two media that can be rented.
boolean removeFromCart (String customerName, String mediaTitle)
Parameters: name - , address -, plan -
Removes the specified media title from the customer's cart.
Parameters:customerName - , mediaTitle -
Returns: false if removal failed for any reason (e. g., customerName not found)
addMovie
void addMovie (String title, int copiesAvailable, String rating)
Adds the specified movie to the database. The possible values for rating are "DR", "HR", "AC".
processRequests
Parameters:title - , copiesAvailable -, rating -
String processRequests ()
addGame
Processes the requests cart of each customer. The customers will be processed in alphabetical order.
void addGame (String title, int copiesAvailable, double weight)
For each customer,
Adds the specified game to the database.
the requests cart will be checked and media will be added to the rented cart, if the plan associated
Parameters:title - , copiesAvailable -, weight -
with the customer
addAlbum
allows it, and if there is a copy of the media available. For UNLIMITED plans the media will be added
void addAlbum (String title, int copiesAvailable, String artist, String songs)
to the rented
Adds the specified album to the database. The songs String includes a list of the title of songs in the
cart always, as long as there are copies associated with the media available. For LIMITED plans, the
album (song
titles are separated by commas).
number of entries
moved from the requests cart to the rented cart will depend on the number of currently rented media,
Parameters: title - , copiesAvailable -, artist -, songs -
and whether copies
setLimitedPlanLimit
associated with the media are available.
Transcribed Image Text:void setLimitedPlanLimit (int value) This set the number of media associated with the LIMITED plan. Parameters: value - getAl1CustomersInfo String getAliCustomersInfo () Returns information about the customers in the database. The information is presented sorted by cus- tomer name. Returns: getAl1MediaInfo String getAl1MediaInfo () Returns information about all the media (movies, albums, and games) that are part of the database. The information Index A: is presented sorted by media title. Returns: MediaRentallnt interface Includes: addToCart Method Detail boolean addToCart (String customerName, String mediaTitle) addCustomer Adds the specified media title to the cart associated with a customer. void addCustomer (String name, String address, String plan) Adds the specified customer to the database. The address is a physical address (not e-mail). The plan Parameters:customerName - , mediaTitle - Returns: false if the mediaTitle is already part of the cart (it will not be added) options available removeFromCart are: LIMITED and UNLIMITED. LIMITED defines a default maximum of two media that can be rented. boolean removeFromCart (String customerName, String mediaTitle) Parameters: name - , address -, plan - Removes the specified media title from the customer's cart. Parameters:customerName - , mediaTitle - Returns: false if removal failed for any reason (e. g., customerName not found) addMovie void addMovie (String title, int copiesAvailable, String rating) Adds the specified movie to the database. The possible values for rating are "DR", "HR", "AC". processRequests Parameters:title - , copiesAvailable -, rating - String processRequests () addGame Processes the requests cart of each customer. The customers will be processed in alphabetical order. void addGame (String title, int copiesAvailable, double weight) For each customer, Adds the specified game to the database. the requests cart will be checked and media will be added to the rented cart, if the plan associated Parameters:title - , copiesAvailable -, weight - with the customer addAlbum allows it, and if there is a copy of the media available. For UNLIMITED plans the media will be added void addAlbum (String title, int copiesAvailable, String artist, String songs) to the rented Adds the specified album to the database. The songs String includes a list of the title of songs in the cart always, as long as there are copies associated with the media available. For LIMITED plans, the album (song titles are separated by commas). number of entries moved from the requests cart to the rented cart will depend on the number of currently rented media, Parameters: title - , copiesAvailable -, artist -, songs - and whether copies setLimitedPlanLimit associated with the media are available.
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps

Blurred answer
Similar questions
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY