package edu.columbia.cs.cs1007.company;

import java.util.ArrayList;
/**
 * A class that represents the president of a company.
 
 @author Julia Stoyanovich, COMS 1007, Summer 2009.
 *
 */

public class President extends Manager {

  /**
   * Constructor: the President has no Manager
   @param person
   @param company
   @param salary
   */
  public President(Person person, Company company, double salary) {
    
    super(person, company, null, salary);
    _reports = new ArrayList<Employee>();
    _title = "President";
  }

  /**
   * This method overrides Manager.hire(): a President only hires Managers, 
   * not regular employees.
   * The managers he hires report to him.
   @param person
   @param salary
   */
  public Manager hire (Person person, double salary) {
    
    Manager manager = new Manager(person, _company, this, salary);
    _reports.add(manager);
    return manager;
  }

}