Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Java question. Inheritance Demonstrate your ability to program using inheritance in the Java programming language. Demonstrate your knowledge of proper equals implementations in the Java

Java question.

image text in transcribed

Inheritance Demonstrate your ability to program using inheritance in the Java programming language. Demonstrate your knowledge of proper equals implementations in the Java programming language. Instructions There are three tasks to complete Create an object hierarchy which mimics the classification for university affiliates. This should proceed logically. The hierarchy should be contained within package. . There should be an abstract base class called UniversityAffiliate There should be the following subtypes. Subtypes in bold should be abstract: Student UndergraduateStudent Graduate Student Employee Faculty Staff Administrator Lecturer Assistant Professor Associate Professor Professor Each of the subtypes should have the following methods: getName returns a name for the person as a String. This value is per object and not defined by the class it should not be used for equality. getAge returns the age of the person as an int. This value is per object and not defined by the class it should be used for equality. Students should have the method: isMatriculated which returns a Boolean Employees should have the methods: getSalary which returns a salary as a double Faculty should have the methods: isTenured which returns a boolean isAdjunct which returns a boolean Staff and Administrator classes should have the method getTitle which returns a String indicating their job title There should be an equals() method to show if two faculty objects have the same values (other than name, which can be different)

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

Object Databases The Essentials

Authors: Mary E. S. Loomis

1st Edition

020156341X, 978-0201563412

More Books

Students also viewed these Databases questions

Question

Provide examples of KPIs in Human Capital Management.

Answered: 1 week ago

Question

What are OLAP Cubes?

Answered: 1 week ago