edu.columbia.cs.cs1007.company
Class President

java.lang.Object
  extended by edu.columbia.cs.cs1007.company.Person
      extended by edu.columbia.cs.cs1007.company.Employee
          extended by edu.columbia.cs.cs1007.company.Manager
              extended by edu.columbia.cs.cs1007.company.President

public class President
extends Manager

A class that represents the president of a company.

Author:
Julia Stoyanovich, COMS 1007, Summer 2009.

Field Summary
 
Fields inherited from class edu.columbia.cs.cs1007.company.Manager
_reports, _title
 
Fields inherited from class edu.columbia.cs.cs1007.company.Employee
_company, _manager
 
Constructor Summary
President(Person person, Company company, double salary)
          Constructor: the President has no Manager
 
Method Summary
 Manager hire(Person person, double salary)
          This method overrides Manager.hire(): a President only hires Managers, not regular employees.
 
Methods inherited from class edu.columbia.cs.cs1007.company.Manager
delegateWork, doWork, fire, giveRaise, toString
 
Methods inherited from class edu.columbia.cs.cs1007.company.Employee
equals, getRaise, getSalary, getStartDate, hasManager
 
Methods inherited from class edu.columbia.cs.cs1007.company.Person
main, nameToString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

President

public President(Person person,
                 Company company,
                 double salary)
Constructor: the President has no Manager

Parameters:
person -
company -
salary -
Method Detail

hire

public Manager hire(Person person,
                    double salary)
This method overrides Manager.hire(): a President only hires Managers, not regular employees. The managers he hires report to him.

Overrides:
hire in class Manager
Parameters:
person -
salary -
Returns:
an instance of Employee