Question: Inheritance Using super in the constructor Using super in the method Method overriding Write an application with four classes Employee, Secretary, Engineer, and Tester class

Inheritance

Using super in the constructor

Using super in the method

Method overriding

Write an application with four classes Employee, Secretary, Engineer, and Tester class with main method in it.

The following characteristics should be used: empID, firstName, lastName, phone, salary, typingSpeed, engineerType.

Characteristics that are applicable to all employees should be instance variables in the Employee class. The others should be in the class(s) where they belong.

Class Employee should have constructor that initializes all its data. Classes Secretary, and Engineer will have constructors which will reuse their parents constructor and provide additional code for initializing their specific data.

Class Employee should have toString method that returns string representtion of all employee data. Classes Secretary, and Engineer will override inherited toString method from class Employee in order to provide appropriate string representation of all data for their classes (which includes inherited data from Employee class and their own data).

Class Tester will instantiate 1-2 objects from those three classes (at least five total) and it will display the information about those objects by invoking their toString methods.

Submit java files with code for all four classes, picture of program run from BlueJ, and picture of UML diagram.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!