code: public int getMaxSlots(TaskTrackerStatus status, TaskType type) {
      return (type == TaskType.MAP) ? status.getMaxMapSlots() :
          status.getMaxReduceSlots();
    }
docs: Obtain the overall number of the slots limit of a tasktracker
  @param status The status of the tasktracker
  @param type The type of the task
  @return The number of maximum slots