Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Media Item Equality: Defining Equality for Java RWOs - writing a .equals() method for Medialtem Song International Software want to get into the Media Song

image text in transcribedimage text in transcribedimage text in transcribed

Media Item Equality: Defining Equality for Java RWOs - writing a .equals() method for Medialtem Song International Software want to get into the Media Song Market with utilities for managing mp3 songs and playlists. To start with they have identified that they need a class to create objects for storing information about songs. This class is called Medialtem and at the moment it only hold information about the title of a song - pretty basic eh? As part of the requirements it has been determined that the software needs to 'know' if two tracks are the same - initially this will be done on the title. It is your task to write a .equals() method for the Medialtem class. This is the required 'business logic': The .equals() method should return true if the title fields match with the object being compared. The match should ignore the case of the strings, and ignore any whitespace at the beginning or end of the strings. The .equals() method should return false if the title field of the object being compared doesn't meet the above criteria or if it is null or of a different type \}

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

Advances In Databases And Information Systems 22nd European Conference Adbis 2018 Budapest Hungary September 2 5 2018 Proceedings Lncs 11019

Authors: Andras Benczur ,Bernhard Thalheim ,Tomas Horvath

1st Edition

3319983970, 978-3319983974

More Books

Students also viewed these Databases questions

Question

Persuasive Speaking Organizing Patterns in Persuasive Speaking?

Answered: 1 week ago