Question

In: Computer Science

Develop a Domain Class Model with proper annotation on paper. Music An album has a name...

Develop a Domain Class Model with proper annotation on paper.

Music

An album has a name and a release date. An album has a collection of 1 or more songs. And a song may be on one album, but does not have to be (that is a song can exist whether it is on an album or not). A song has a title and a length in seconds. A song is created by one artist. All artists have a name. There are different kinds of artists. An artist can be an individual person. That is a person is an artist. A group is also an artist. A person has a birth date and a favorite color. And a group has a date that it was established. An artist can perform one or more songs.

Examples:

Lizzo is a person who is an artist. Lizzo was born on April 27, 1988 and her favorite color is orange. Lizzo sings songs like Good as Hell (2 min 38 seconds) and Truth Hurts (2 min 53 seconds). Truth Hurts is on the album Cuz I Love You (2019). Good as Hell is on Coconut Oil (2016).

The Revivalists are a group that is an artist and was established in 2007. The Revivalists have four studio albums: Vital Signs (2010), City of Sound (2014), Men Amongst Mountains (2015) and Take Good Care (2018). The song Wish I knew You is on the album Men Amongst Mountains, and is 4 min 34 seconds.

Solutions

Expert Solution

Domain Class Diagram for the given requirement is:

No of Classes :

  • 1. Album Class
  • 2. Song Class
  • 3. Artist Class
  • 4. Individual Class
  • 5. Group Class

Relationship:

  • There are collect relationship between Album class and Song class
  • There are Created By relationship between Songs class Artist class
  • There are generalization between Artist class, Individual class and Group class

Multiplicity :

  • There are 1:M multiplicity between Album class and Song class
  • There are M:1 multiplicity between Songs class Artist class

Diagram :


Related Solutions

Design a class that holds the following data regarding a music album: artist, title, number of...
Design a class that holds the following data regarding a music album: artist, title, number of tracks, and year released. Write appropriate accessor and mutator methods. Also, write a program that creates three instances of the class. Each instance will hold information about a different music album. Make sure to display all of the information for all three albums to the screen in an organized manner. **Using python**
C++ Design a class named TermPaper that holds an author's name, the subject of the paper,...
C++ Design a class named TermPaper that holds an author's name, the subject of the paper, and an assigned letter grade. Include methods to set the values for each data field and display the values for each data field. Create the class diagram and write the pseudocode that defines the class. Pseudocode help please
Develop a java program with a class named friend with data members like name, phno and...
Develop a java program with a class named friend with data members like name, phno and hobby. Use Parameterized constructor to create two friend objects and invoke checkhobby method which takes only one parameter, to find whether they have same hobby or different hobbies
IN JAVA ECLIPSE PLEASE The xxx_Student class A Student has a: – Name - the name...
IN JAVA ECLIPSE PLEASE The xxx_Student class A Student has a: – Name - the name consists of the First and Last name separated by a space. – Student Id – a whole number automatically assigned in the student class – Student id numbers start at 100. The numbers are assigned using a static variable in the Student class • Include all instance variables • Getters and setters for instance variables • A static variable used to assign the student...
Using C#: Write a class named Employee that has the following properties: Name - The Name...
Using C#: Write a class named Employee that has the following properties: Name - The Name property holds the employee's name IdNumber - The IdNumber property holds the employee's ID number Department - The Department property holds the name of the department in which the employee works Position - The Position property holds the employee's job title The class should have the following overloaded constructors: A constructor that accepts the following values as arguments and assigns them to the appropriate...
Write a program that utilizes a Professor class. A professor has a first name, last name,...
Write a program that utilizes a Professor class. A professor has a first name, last name, affiliation, easiness grade, and a helpfulness grade. Grades range from 1 (lowest) to 5 (highest). The Professor class has two constructors. The first constructor initiates the object with just the first name, the last name, and the affiliation. The default value for easiness and helpfulness grade is 3. The second constructor initiates the object using the first name, the last name, the affiliation, and...
A Java question. You are given a Student class. A Student has a name and an...
A Java question. You are given a Student class. A Student has a name and an ArrayList of grades (Doubles) as instance variables. Write a class named Classroom which manages Student objects. You will provide the following: 1. public Classroom() a no-argument constructor. 2. public void add(Student s) adds the student to this Classroom (to an ArrayList 3. public String hasAverageGreaterThan(double target) gets the name of the first student in the Classroom who has an average greater than the target...
Design a Ship class that has the following members: • A member variable for the name...
Design a Ship class that has the following members: • A member variable for the name of the ship (a string) • A member variable for the year that the ship was built (a string) • A constructor and appropriate accessors and mutators • A virtual print function that displays the ship’s name and the year it was built. Design a CruiseShip class that is derived from the Ship class. The CruiseShip class should have the following members: • A...
Find a poll online or paper-based that has not been used in the class. Analyze and...
Find a poll online or paper-based that has not been used in the class. Analyze and evaluate the poll using the 4 critical questions to determine whether the poll is problematic or not.
Design a ship class that has the following data fields: A data field for the name...
Design a ship class that has the following data fields: A data field for the name of the ship (a string). A data field for the year that the ship was built (a String). A constructor and appropriate accessors and mutators. A toString method that displays the ship’s name and the year it was built. Design a CruiseShip class that extends the Ship class. The CruiseShip class should have the following member: A field for the maximum number of passengers...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT