subject

For this assignment, you are going to enhance the Employee Hierarchy that you created in Programming Assignment 2. The following are the requirements to modify programming Assignment 2: 1) Make the Employee Class an abstract class and declare in it the abstract method earnings().
2) Add the abstract method void raise(double percent) to the Employee class.
3) Implement the raise method in each of the subclasses in the following manner: CommissionEmployee Class - increase the commission rate by the percent specified. Class - increase the commission rate by the percent specified and increase the base salary by the percent specified. SalariedEmployee - increase the salary by the percent specified. HourlyEmployee - increase the hourly wage by the percent specified.
4) In your main method, after the code from Programming Assignment 2, you will add code to polymorphically process an array of Employees to give each employee a raise. You will create a 5 element Employee array and assign each of the 5 employees to an element of the array. You will then write an java enhanced for loop to loop through the array and give each employee a 2 percent raise except SalariedEmployees will be given a 4 percent raise. Print out each employee to show the new information for each employee.
You should use good standard programming practices in all of your coding.
The output from your program should look like the following:
Employee information.
Commissioned Employee: Fred Jones with ssn: 111-11-1111
Gross Sales: 2000.00
Commission Rate: 0.0500
Earnings: $100.00
Base Salary Plus Commissioned Employee: Sue Smith with ssn: 222-22-2222
Gross Sales: 3000.00
Commission Rate: 0.0500
with Base Salary of: $300.00
Earnings: $450.00
Salaried Employee: Sha Yang with ssn: 333-33-3333
Salary: 1150.00
Earnings: $1150.00
Hourly Employee: Ian Tanning with ssn: 444-44-4444
Hourly Wage: 15.00
Hours Worked: 50.00
Earnings: $825.00
Hourly Employee: Angela Domchek with ssn: 555-55-5555
Hourly Wage: 20.00
Hours Worked: 40.00
Earnings: $800.00
Employee information after raises.
Commissioned Employee:
Fred Jones with ssn: 111-11-1111
Gross Sales: 2000.00
Commission Rate: 0.0510
Earnings: $102.00
Base Salary Plus Commissioned Employee: Sue Smith with ssn: 222-22-2222
Gross Sales: 3000.00
Commission Rate: 0.0510
with Base Salary of: $306.00
Earnings: $459.00
Salaried Employee: Sha Yang with ssn: 333-33-3333
Salary: 1196.00
Earnings: $1196.00
Hourly Employee: Ian Tanning with ssn: 444-44-4444
Hourly Wage: 15.30
Hours Worked: 50.00
Earnings: $841.50
Hourly Employee: Angela Domchek with ssn: 555-55-5555
Hourly Wage: 20.40
Hours Worked: 40.00
Earnings: $816.00

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 00:00
Donna and her team of five have invented a new gadget for the science exhibition in their college. which intellectual property right will protect their invention?
Answers: 1
question
Computers and Technology, 23.06.2019 04:00
Write a method that takes in an array of point2d objects, and then analyzes the dataset to find points that are close together. be sure to review the point2d api. in your method, if the distance between any pair of points is less than 10, display the distance and the (x,y)s of each point. for example, "the distance between (3,5) and (8,9) is 6.40312." the complete api for the point2d adt may be viewed at ~pf/sedgewick-wayne/algs4/documentation/point2d.html (links to an external site.)links to an external site.. try to write your program directly from the api - do not review the adt's source code.
Answers: 1
question
Computers and Technology, 23.06.2019 21:40
Simon says is a memory game where "simon" outputs a sequence of 10 characters (r, g, b, y) and the user must repeat the sequence. create a for loop that compares the two strings. for each match, add one point to user_score. upon a mismatch, end the game. sample output with inputs: 'rrgbryybgy' 'rrgbbrybgy'
Answers: 3
question
Computers and Technology, 24.06.2019 06:50
What are the things you are considering before uploading photos on social media?
Answers: 1
You know the right answer?
For this assignment, you are going to enhance the Employee Hierarchy that you created in Programming...
Questions
question
Mathematics, 13.10.2019 11:00
question
Geography, 13.10.2019 11:00
Questions on the website: 13722362