// CSE 142, Autumn 2009, Marty Stepp // A class to represent lawyers. // This version has a constructor and now calls overridden methods // and the superclass's constructor using the super keyword. public class Lawyer extends Employee { public Lawyer(int years) { super(years); // call the Employee(int) constructor, passing years } // Modified. normal salary plus $5k raise per year public double getSalary() { return super.getSalary() + 5000 * getYears(); } // Modified. normal vacation plus 5 days public int getVacationDays() { return super.getVacationDays() + 5; // 3 weeks vacation } public String getVacationForm() { return "pink"; } public void sue() { System.out.println("I'll see you in court!"); } }