Answered step by step
Verified Expert Solution
Question
1 Approved Answer
/ / A class to represent employees in general. public class Employee { public int getHours ( ) { return baseHours; / / 4 0
A class to represent employees in general.
public class Employee
public int getHours
return baseHours; hoursweek
public double getSalary
return baseSalary; $
public int getVacationDays
return baseVacationDays; days
public String getVacationForm
return baseVacationForm; yellow
These are so that test cases can change the base values
and make sure that subclasses also change their values.
Your code that you submit is NOT supposed to directly use, call,
or modify the values below! They are here only to help PracticeIt
successfully test your code. Please ignore them.
private int baseHours ;
private double baseSalary ;
private int baseVacationDays ;
private String baseVacationForm "yellow";
public final void setBaseHoursint hours
baseHours hours;
public final void setBaseSalarydouble salary
baseSalary salary;
public final void setBaseVacationDaysint days
baseVacationDays days;
public final void setBaseVacationFormString form
baseVacationForm form;
Write the class Marketer to accompany the other law firm classes described in this chapter. Marketers make $$ more than general employees and have an additional method called advertise that prints "Act now, while supplies last!" Make sure to interact with the Employee superclass as appropriate.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started