Question: THIS IS A JAVA PROGRAM Assignment Description: During this homework, you will be implementing the following class hierarchy that implements university systems. In this university
THIS IS A JAVA PROGRAM
Assignment Description: During this homework, you will be implementing the following class hierarchy that implements university systems. In this university system, the university is associated with multiple people types. People can be Employee type or Student type. Employee can be either Faculty or Staff. The following class diagram show the relationship among objects.

Description of Each Object University: Maintains a list of people and various functionalities associated with the
university. Please see the partially completed University.java program
People: This is the object at the top of the object hierarchy. Constructor of the People class take first_name, last_name, and the phone number as parameters. It sets the payRate and the monthlyPay to zero. payRate will represent the academic year salary for each type of employee in the employee class. The toString method will return the first_name , last_name, and the phone number. calculatePay() method will set the monthlyPay to zero. The getName() method returns the first name and the last name.
Employee: The Employee class has an additional data member, payScale, that will be common for both faculty and Staff. payScale is either 9 month or 12 month. So, the input for this is either 9 or 12. The constructor of the Employee class takes the first_name, last_name, phone number, payRate, and the payScale as parameters.
Faculty: The faculty class has additional data members: department and classesTeach. The constructor of the Faculty class takes the first_name, last_name, phone number, payRate, payScale, and the department as parameters. The addClass method takes the name of the class and add to the classesTeach arraylist. The toString method will returns the first_name, last_name, classes teach, and the monthly pay. Finally the calculatePay method will calculate the monthly pay using the following equations
monthlyPay = payRate/payScale + 500*number of classes teach
Staff: The Staff class has an additional data member title that represents the job title. The constructor of the Staff class takes the first_name, last_name, phone number, payRate, payScale, and the title as parameters. The toString method will returns the first_name, last_name, title, and the monthly pay
Finally the calculatePay method will calculate the monthly pay using the following equations
monthlyPay = payRate/payScale
Student: The Student class has additional data members gpa and the major. The constructor of the Student will takes the first_name, last_name, phone number and the major as parameters. It sets the gpa to zero. The setGpa method will take the new gpa as a parameter and change the object gpa value. The changeMajor method take the major
as a parameter and change the major of the Student object. The toString method will return the first_name, last_name, phone number, major, and the gpa.
6 as dlaBrann show the relationship among objects. University name: String location: String people Peoplen + static void main) People whirst name: String last name String n] #phoneNumber:String #payRate double #monthlyPay double People(String, String String calculatePayO String getNameo toStrin Student Employee major String gpa double Student String String. String. String) void setcpa(double) evoid changeMajor(String) payScaleint Employee(String String, String. int double) to Faculty Statf department String classesTeach Stringl Facuity String String, String double int Strng) void addciass(String) rvoid calculatePay0 String toString sde String +StariString String, String double, int, string) Sring toStingo evoid calculatePayO)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
