/**
 * Autogenerated by Thrift Compiler (0.7.0)
 *
 * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
 */
package org.apache.hadoop.thriftfs.jobtracker.api;

import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.util.HashMap;
import java.util.EnumMap;
import java.util.Set;
import java.util.HashSet;
import java.util.EnumSet;
import java.util.Collections;
import java.util.BitSet;
import java.nio.ByteBuffer;
import java.util.Arrays;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
 * Describes the current state of a single attempt
 */
public class ThriftTaskStatus implements org.apache.thrift.TBase<ThriftTaskStatus, ThriftTaskStatus._Fields>, java.io.Serializable, Cloneable {
  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ThriftTaskStatus");

  private static final org.apache.thrift.protocol.TField TASK_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("taskID", org.apache.thrift.protocol.TType.STRUCT, (short)1);
  private static final org.apache.thrift.protocol.TField PROGRESS_FIELD_DESC = new org.apache.thrift.protocol.TField("progress", org.apache.thrift.protocol.TType.DOUBLE, (short)2);
  private static final org.apache.thrift.protocol.TField STATE_FIELD_DESC = new org.apache.thrift.protocol.TField("state", org.apache.thrift.protocol.TType.I32, (short)3);
  private static final org.apache.thrift.protocol.TField DIAGNOSTIC_INFO_FIELD_DESC = new org.apache.thrift.protocol.TField("diagnosticInfo", org.apache.thrift.protocol.TType.STRING, (short)4);
  private static final org.apache.thrift.protocol.TField STATE_STRING_FIELD_DESC = new org.apache.thrift.protocol.TField("stateString", org.apache.thrift.protocol.TType.STRING, (short)5);
  private static final org.apache.thrift.protocol.TField TASK_TRACKER_FIELD_DESC = new org.apache.thrift.protocol.TField("taskTracker", org.apache.thrift.protocol.TType.STRING, (short)6);
  private static final org.apache.thrift.protocol.TField START_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("startTime", org.apache.thrift.protocol.TType.I64, (short)7);
  private static final org.apache.thrift.protocol.TField FINISH_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("finishTime", org.apache.thrift.protocol.TType.I64, (short)8);
  private static final org.apache.thrift.protocol.TField OUTPUT_SIZE_FIELD_DESC = new org.apache.thrift.protocol.TField("outputSize", org.apache.thrift.protocol.TType.I64, (short)9);
  private static final org.apache.thrift.protocol.TField PHASE_FIELD_DESC = new org.apache.thrift.protocol.TField("phase", org.apache.thrift.protocol.TType.I32, (short)10);
  private static final org.apache.thrift.protocol.TField COUNTERS_FIELD_DESC = new org.apache.thrift.protocol.TField("counters", org.apache.thrift.protocol.TType.STRUCT, (short)11);
  private static final org.apache.thrift.protocol.TField SHUFFLE_FINISH_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("shuffleFinishTime", org.apache.thrift.protocol.TType.I64, (short)12);
  private static final org.apache.thrift.protocol.TField SORT_FINISH_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("sortFinishTime", org.apache.thrift.protocol.TType.I64, (short)13);
  private static final org.apache.thrift.protocol.TField MAP_FINISH_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("mapFinishTime", org.apache.thrift.protocol.TType.I64, (short)14);

  public ThriftTaskAttemptID taskID; // required
  public double progress; // required
  /**
   * 
   * @see ThriftTaskState
   */
  public ThriftTaskState state; // required
  public String diagnosticInfo; // required
  public String stateString; // required
  public String taskTracker; // required
  public long startTime; // required
  public long finishTime; // required
  public long outputSize; // required
  /**
   * 
   * @see ThriftTaskPhase
   */
  public ThriftTaskPhase phase; // required
  public ThriftGroupList counters; // required
  public long shuffleFinishTime; // required
  public long sortFinishTime; // required
  public long mapFinishTime; // required

  /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
  public enum _Fields implements org.apache.thrift.TFieldIdEnum {
    TASK_ID((short)1, "taskID"),
    PROGRESS((short)2, "progress"),
    /**
     * 
     * @see ThriftTaskState
     */
    STATE((short)3, "state"),
    DIAGNOSTIC_INFO((short)4, "diagnosticInfo"),
    STATE_STRING((short)5, "stateString"),
    TASK_TRACKER((short)6, "taskTracker"),
    START_TIME((short)7, "startTime"),
    FINISH_TIME((short)8, "finishTime"),
    OUTPUT_SIZE((short)9, "outputSize"),
    /**
     * 
     * @see ThriftTaskPhase
     */
    PHASE((short)10, "phase"),
    COUNTERS((short)11, "counters"),
    SHUFFLE_FINISH_TIME((short)12, "shuffleFinishTime"),
    SORT_FINISH_TIME((short)13, "sortFinishTime"),
    MAP_FINISH_TIME((short)14, "mapFinishTime");

    private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();

    static {
      for (_Fields field : EnumSet.allOf(_Fields.class)) {
        byName.put(field.getFieldName(), field);
      }
    }

    /**
     * Find the _Fields constant that matches fieldId, or null if its not found.
     */
    public static _Fields findByThriftId(int fieldId) {
      switch(fieldId) {
        case 1: // TASK_ID
          return TASK_ID;
        case 2: // PROGRESS
          return PROGRESS;
        case 3: // STATE
          return STATE;
        case 4: // DIAGNOSTIC_INFO
          return DIAGNOSTIC_INFO;
        case 5: // STATE_STRING
          return STATE_STRING;
        case 6: // TASK_TRACKER
          return TASK_TRACKER;
        case 7: // START_TIME
          return START_TIME;
        case 8: // FINISH_TIME
          return FINISH_TIME;
        case 9: // OUTPUT_SIZE
          return OUTPUT_SIZE;
        case 10: // PHASE
          return PHASE;
        case 11: // COUNTERS
          return COUNTERS;
        case 12: // SHUFFLE_FINISH_TIME
          return SHUFFLE_FINISH_TIME;
        case 13: // SORT_FINISH_TIME
          return SORT_FINISH_TIME;
        case 14: // MAP_FINISH_TIME
          return MAP_FINISH_TIME;
        default:
          return null;
      }
    }

    /**
     * Find the _Fields constant that matches fieldId, throwing an exception
     * if it is not found.
     */
    public static _Fields findByThriftIdOrThrow(int fieldId) {
      _Fields fields = findByThriftId(fieldId);
      if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
      return fields;
    }

    /**
     * Find the _Fields constant that matches name, or null if its not found.
     */
    public static _Fields findByName(String name) {
      return byName.get(name);
    }

    private final short _thriftId;
    private final String _fieldName;

    _Fields(short thriftId, String fieldName) {
      _thriftId = thriftId;
      _fieldName = fieldName;
    }

    public short getThriftFieldId() {
      return _thriftId;
    }

    public String getFieldName() {
      return _fieldName;
    }
  }

  // isset id assignments
  private static final int __PROGRESS_ISSET_ID = 0;
  private static final int __STARTTIME_ISSET_ID = 1;
  private static final int __FINISHTIME_ISSET_ID = 2;
  private static final int __OUTPUTSIZE_ISSET_ID = 3;
  private static final int __SHUFFLEFINISHTIME_ISSET_ID = 4;
  private static final int __SORTFINISHTIME_ISSET_ID = 5;
  private static final int __MAPFINISHTIME_ISSET_ID = 6;
  private BitSet __isset_bit_vector = new BitSet(7);

  public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
  static {
    Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
    tmpMap.put(_Fields.TASK_ID, new org.apache.thrift.meta_data.FieldMetaData("taskID", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ThriftTaskAttemptID.class)));
    tmpMap.put(_Fields.PROGRESS, new org.apache.thrift.meta_data.FieldMetaData("progress", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
    tmpMap.put(_Fields.STATE, new org.apache.thrift.meta_data.FieldMetaData("state", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, ThriftTaskState.class)));
    tmpMap.put(_Fields.DIAGNOSTIC_INFO, new org.apache.thrift.meta_data.FieldMetaData("diagnosticInfo", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
    tmpMap.put(_Fields.STATE_STRING, new org.apache.thrift.meta_data.FieldMetaData("stateString", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
    tmpMap.put(_Fields.TASK_TRACKER, new org.apache.thrift.meta_data.FieldMetaData("taskTracker", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
    tmpMap.put(_Fields.START_TIME, new org.apache.thrift.meta_data.FieldMetaData("startTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
    tmpMap.put(_Fields.FINISH_TIME, new org.apache.thrift.meta_data.FieldMetaData("finishTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
    tmpMap.put(_Fields.OUTPUT_SIZE, new org.apache.thrift.meta_data.FieldMetaData("outputSize", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
    tmpMap.put(_Fields.PHASE, new org.apache.thrift.meta_data.FieldMetaData("phase", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, ThriftTaskPhase.class)));
    tmpMap.put(_Fields.COUNTERS, new org.apache.thrift.meta_data.FieldMetaData("counters", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ThriftGroupList.class)));
    tmpMap.put(_Fields.SHUFFLE_FINISH_TIME, new org.apache.thrift.meta_data.FieldMetaData("shuffleFinishTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
    tmpMap.put(_Fields.SORT_FINISH_TIME, new org.apache.thrift.meta_data.FieldMetaData("sortFinishTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
    tmpMap.put(_Fields.MAP_FINISH_TIME, new org.apache.thrift.meta_data.FieldMetaData("mapFinishTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
    metaDataMap = Collections.unmodifiableMap(tmpMap);
    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ThriftTaskStatus.class, metaDataMap);
  }

  public ThriftTaskStatus() {
  }

  public ThriftTaskStatus(
    ThriftTaskAttemptID taskID,
    double progress,
    ThriftTaskState state,
    String diagnosticInfo,
    String stateString,
    String taskTracker,
    long startTime,
    long finishTime,
    long outputSize,
    ThriftTaskPhase phase,
    ThriftGroupList counters,
    long shuffleFinishTime,
    long sortFinishTime,
    long mapFinishTime)
  {
    this();
    this.taskID = taskID;
    this.progress = progress;
    setProgressIsSet(true);
    this.state = state;
    this.diagnosticInfo = diagnosticInfo;
    this.stateString = stateString;
    this.taskTracker = taskTracker;
    this.startTime = startTime;
    setStartTimeIsSet(true);
    this.finishTime = finishTime;
    setFinishTimeIsSet(true);
    this.outputSize = outputSize;
    setOutputSizeIsSet(true);
    this.phase = phase;
    this.counters = counters;
    this.shuffleFinishTime = shuffleFinishTime;
    setShuffleFinishTimeIsSet(true);
    this.sortFinishTime = sortFinishTime;
    setSortFinishTimeIsSet(true);
    this.mapFinishTime = mapFinishTime;
    setMapFinishTimeIsSet(true);
  }

  /**
   * Performs a deep copy on <i>other</i>.
   */
  public ThriftTaskStatus(ThriftTaskStatus other) {
    __isset_bit_vector.clear();
    __isset_bit_vector.or(other.__isset_bit_vector);
    if (other.isSetTaskID()) {
      this.taskID = new ThriftTaskAttemptID(other.taskID);
    }
    this.progress = other.progress;
    if (other.isSetState()) {
      this.state = other.state;
    }
    if (other.isSetDiagnosticInfo()) {
      this.diagnosticInfo = other.diagnosticInfo;
    }
    if (other.isSetStateString()) {
      this.stateString = other.stateString;
    }
    if (other.isSetTaskTracker()) {
      this.taskTracker = other.taskTracker;
    }
    this.startTime = other.startTime;
    this.finishTime = other.finishTime;
    this.outputSize = other.outputSize;
    if (other.isSetPhase()) {
      this.phase = other.phase;
    }
    if (other.isSetCounters()) {
      this.counters = new ThriftGroupList(other.counters);
    }
    this.shuffleFinishTime = other.shuffleFinishTime;
    this.sortFinishTime = other.sortFinishTime;
    this.mapFinishTime = other.mapFinishTime;
  }

  public ThriftTaskStatus deepCopy() {
    return new ThriftTaskStatus(this);
  }

  @Override
  public void clear() {
    this.taskID = null;
    setProgressIsSet(false);
    this.progress = 0.0;
    this.state = null;
    this.diagnosticInfo = null;
    this.stateString = null;
    this.taskTracker = null;
    setStartTimeIsSet(false);
    this.startTime = 0;
    setFinishTimeIsSet(false);
    this.finishTime = 0;
    setOutputSizeIsSet(false);
    this.outputSize = 0;
    this.phase = null;
    this.counters = null;
    setShuffleFinishTimeIsSet(false);
    this.shuffleFinishTime = 0;
    setSortFinishTimeIsSet(false);
    this.sortFinishTime = 0;
    setMapFinishTimeIsSet(false);
    this.mapFinishTime = 0;
  }

  public ThriftTaskAttemptID getTaskID() {
    return this.taskID;
  }

  public ThriftTaskStatus setTaskID(ThriftTaskAttemptID taskID) {
    this.taskID = taskID;
    return this;
  }

  public void unsetTaskID() {
    this.taskID = null;
  }

  /** Returns true if field taskID is set (has been assigned a value) and false otherwise */
  public boolean isSetTaskID() {
    return this.taskID != null;
  }

  public void setTaskIDIsSet(boolean value) {
    if (!value) {
      this.taskID = null;
    }
  }

  public double getProgress() {
    return this.progress;
  }

  public ThriftTaskStatus setProgress(double progress) {
    this.progress = progress;
    setProgressIsSet(true);
    return this;
  }

  public void unsetProgress() {
    __isset_bit_vector.clear(__PROGRESS_ISSET_ID);
  }

  /** Returns true if field progress is set (has been assigned a value) and false otherwise */
  public boolean isSetProgress() {
    return __isset_bit_vector.get(__PROGRESS_ISSET_ID);
  }

  public void setProgressIsSet(boolean value) {
    __isset_bit_vector.set(__PROGRESS_ISSET_ID, value);
  }

  /**
   * 
   * @see ThriftTaskState
   */
  public ThriftTaskState getState() {
    return this.state;
  }

  /**
   * 
   * @see ThriftTaskState
   */
  public ThriftTaskStatus setState(ThriftTaskState state) {
    this.state = state;
    return this;
  }

  public void unsetState() {
    this.state = null;
  }

  /** Returns true if field state is set (has been assigned a value) and false otherwise */
  public boolean isSetState() {
    return this.state != null;
  }

  public void setStateIsSet(boolean value) {
    if (!value) {
      this.state = null;
    }
  }

  public String getDiagnosticInfo() {
    return this.diagnosticInfo;
  }

  public ThriftTaskStatus setDiagnosticInfo(String diagnosticInfo) {
    this.diagnosticInfo = diagnosticInfo;
    return this;
  }

  public void unsetDiagnosticInfo() {
    this.diagnosticInfo = null;
  }

  /** Returns true if field diagnosticInfo is set (has been assigned a value) and false otherwise */
  public boolean isSetDiagnosticInfo() {
    return this.diagnosticInfo != null;
  }

  public void setDiagnosticInfoIsSet(boolean value) {
    if (!value) {
      this.diagnosticInfo = null;
    }
  }

  public String getStateString() {
    return this.stateString;
  }

  public ThriftTaskStatus setStateString(String stateString) {
    this.stateString = stateString;
    return this;
  }

  public void unsetStateString() {
    this.stateString = null;
  }

  /** Returns true if field stateString is set (has been assigned a value) and false otherwise */
  public boolean isSetStateString() {
    return this.stateString != null;
  }

  public void setStateStringIsSet(boolean value) {
    if (!value) {
      this.stateString = null;
    }
  }

  public String getTaskTracker() {
    return this.taskTracker;
  }

  public ThriftTaskStatus setTaskTracker(String taskTracker) {
    this.taskTracker = taskTracker;
    return this;
  }

  public void unsetTaskTracker() {
    this.taskTracker = null;
  }

  /** Returns true if field taskTracker is set (has been assigned a value) and false otherwise */
  public boolean isSetTaskTracker() {
    return this.taskTracker != null;
  }

  public void setTaskTrackerIsSet(boolean value) {
    if (!value) {
      this.taskTracker = null;
    }
  }

  public long getStartTime() {
    return this.startTime;
  }

  public ThriftTaskStatus setStartTime(long startTime) {
    this.startTime = startTime;
    setStartTimeIsSet(true);
    return this;
  }

  public void unsetStartTime() {
    __isset_bit_vector.clear(__STARTTIME_ISSET_ID);
  }

  /** Returns true if field startTime is set (has been assigned a value) and false otherwise */
  public boolean isSetStartTime() {
    return __isset_bit_vector.get(__STARTTIME_ISSET_ID);
  }

  public void setStartTimeIsSet(boolean value) {
    __isset_bit_vector.set(__STARTTIME_ISSET_ID, value);
  }

  public long getFinishTime() {
    return this.finishTime;
  }

  public ThriftTaskStatus setFinishTime(long finishTime) {
    this.finishTime = finishTime;
    setFinishTimeIsSet(true);
    return this;
  }

  public void unsetFinishTime() {
    __isset_bit_vector.clear(__FINISHTIME_ISSET_ID);
  }

  /** Returns true if field finishTime is set (has been assigned a value) and false otherwise */
  public boolean isSetFinishTime() {
    return __isset_bit_vector.get(__FINISHTIME_ISSET_ID);
  }

  public void setFinishTimeIsSet(boolean value) {
    __isset_bit_vector.set(__FINISHTIME_ISSET_ID, value);
  }

  public long getOutputSize() {
    return this.outputSize;
  }

  public ThriftTaskStatus setOutputSize(long outputSize) {
    this.outputSize = outputSize;
    setOutputSizeIsSet(true);
    return this;
  }

  public void unsetOutputSize() {
    __isset_bit_vector.clear(__OUTPUTSIZE_ISSET_ID);
  }

  /** Returns true if field outputSize is set (has been assigned a value) and false otherwise */
  public boolean isSetOutputSize() {
    return __isset_bit_vector.get(__OUTPUTSIZE_ISSET_ID);
  }

  public void setOutputSizeIsSet(boolean value) {
    __isset_bit_vector.set(__OUTPUTSIZE_ISSET_ID, value);
  }

  /**
   * 
   * @see ThriftTaskPhase
   */
  public ThriftTaskPhase getPhase() {
    return this.phase;
  }

  /**
   * 
   * @see ThriftTaskPhase
   */
  public ThriftTaskStatus setPhase(ThriftTaskPhase phase) {
    this.phase = phase;
    return this;
  }

  public void unsetPhase() {
    this.phase = null;
  }

  /** Returns true if field phase is set (has been assigned a value) and false otherwise */
  public boolean isSetPhase() {
    return this.phase != null;
  }

  public void setPhaseIsSet(boolean value) {
    if (!value) {
      this.phase = null;
    }
  }

  public ThriftGroupList getCounters() {
    return this.counters;
  }

  public ThriftTaskStatus setCounters(ThriftGroupList counters) {
    this.counters = counters;
    return this;
  }

  public void unsetCounters() {
    this.counters = null;
  }

  /** Returns true if field counters is set (has been assigned a value) and false otherwise */
  public boolean isSetCounters() {
    return this.counters != null;
  }

  public void setCountersIsSet(boolean value) {
    if (!value) {
      this.counters = null;
    }
  }

  public long getShuffleFinishTime() {
    return this.shuffleFinishTime;
  }

  public ThriftTaskStatus setShuffleFinishTime(long shuffleFinishTime) {
    this.shuffleFinishTime = shuffleFinishTime;
    setShuffleFinishTimeIsSet(true);
    return this;
  }

  public void unsetShuffleFinishTime() {
    __isset_bit_vector.clear(__SHUFFLEFINISHTIME_ISSET_ID);
  }

  /** Returns true if field shuffleFinishTime is set (has been assigned a value) and false otherwise */
  public boolean isSetShuffleFinishTime() {
    return __isset_bit_vector.get(__SHUFFLEFINISHTIME_ISSET_ID);
  }

  public void setShuffleFinishTimeIsSet(boolean value) {
    __isset_bit_vector.set(__SHUFFLEFINISHTIME_ISSET_ID, value);
  }

  public long getSortFinishTime() {
    return this.sortFinishTime;
  }

  public ThriftTaskStatus setSortFinishTime(long sortFinishTime) {
    this.sortFinishTime = sortFinishTime;
    setSortFinishTimeIsSet(true);
    return this;
  }

  public void unsetSortFinishTime() {
    __isset_bit_vector.clear(__SORTFINISHTIME_ISSET_ID);
  }

  /** Returns true if field sortFinishTime is set (has been assigned a value) and false otherwise */
  public boolean isSetSortFinishTime() {
    return __isset_bit_vector.get(__SORTFINISHTIME_ISSET_ID);
  }

  public void setSortFinishTimeIsSet(boolean value) {
    __isset_bit_vector.set(__SORTFINISHTIME_ISSET_ID, value);
  }

  public long getMapFinishTime() {
    return this.mapFinishTime;
  }

  public ThriftTaskStatus setMapFinishTime(long mapFinishTime) {
    this.mapFinishTime = mapFinishTime;
    setMapFinishTimeIsSet(true);
    return this;
  }

  public void unsetMapFinishTime() {
    __isset_bit_vector.clear(__MAPFINISHTIME_ISSET_ID);
  }

  /** Returns true if field mapFinishTime is set (has been assigned a value) and false otherwise */
  public boolean isSetMapFinishTime() {
    return __isset_bit_vector.get(__MAPFINISHTIME_ISSET_ID);
  }

  public void setMapFinishTimeIsSet(boolean value) {
    __isset_bit_vector.set(__MAPFINISHTIME_ISSET_ID, value);
  }

  public void setFieldValue(_Fields field, Object value) {
    switch (field) {
    case TASK_ID:
      if (value == null) {
        unsetTaskID();
      } else {
        setTaskID((ThriftTaskAttemptID)value);
      }
      break;

    case PROGRESS:
      if (value == null) {
        unsetProgress();
      } else {
        setProgress((Double)value);
      }
      break;

    case STATE:
      if (value == null) {
        unsetState();
      } else {
        setState((ThriftTaskState)value);
      }
      break;

    case DIAGNOSTIC_INFO:
      if (value == null) {
        unsetDiagnosticInfo();
      } else {
        setDiagnosticInfo((String)value);
      }
      break;

    case STATE_STRING:
      if (value == null) {
        unsetStateString();
      } else {
        setStateString((String)value);
      }
      break;

    case TASK_TRACKER:
      if (value == null) {
        unsetTaskTracker();
      } else {
        setTaskTracker((String)value);
      }
      break;

    case START_TIME:
      if (value == null) {
        unsetStartTime();
      } else {
        setStartTime((Long)value);
      }
      break;

    case FINISH_TIME:
      if (value == null) {
        unsetFinishTime();
      } else {
        setFinishTime((Long)value);
      }
      break;

    case OUTPUT_SIZE:
      if (value == null) {
        unsetOutputSize();
      } else {
        setOutputSize((Long)value);
      }
      break;

    case PHASE:
      if (value == null) {
        unsetPhase();
      } else {
        setPhase((ThriftTaskPhase)value);
      }
      break;

    case COUNTERS:
      if (value == null) {
        unsetCounters();
      } else {
        setCounters((ThriftGroupList)value);
      }
      break;

    case SHUFFLE_FINISH_TIME:
      if (value == null) {
        unsetShuffleFinishTime();
      } else {
        setShuffleFinishTime((Long)value);
      }
      break;

    case SORT_FINISH_TIME:
      if (value == null) {
        unsetSortFinishTime();
      } else {
        setSortFinishTime((Long)value);
      }
      break;

    case MAP_FINISH_TIME:
      if (value == null) {
        unsetMapFinishTime();
      } else {
        setMapFinishTime((Long)value);
      }
      break;

    }
  }

  public Object getFieldValue(_Fields field) {
    switch (field) {
    case TASK_ID:
      return getTaskID();

    case PROGRESS:
      return Double.valueOf(getProgress());

    case STATE:
      return getState();

    case DIAGNOSTIC_INFO:
      return getDiagnosticInfo();

    case STATE_STRING:
      return getStateString();

    case TASK_TRACKER:
      return getTaskTracker();

    case START_TIME:
      return Long.valueOf(getStartTime());

    case FINISH_TIME:
      return Long.valueOf(getFinishTime());

    case OUTPUT_SIZE:
      return Long.valueOf(getOutputSize());

    case PHASE:
      return getPhase();

    case COUNTERS:
      return getCounters();

    case SHUFFLE_FINISH_TIME:
      return Long.valueOf(getShuffleFinishTime());

    case SORT_FINISH_TIME:
      return Long.valueOf(getSortFinishTime());

    case MAP_FINISH_TIME:
      return Long.valueOf(getMapFinishTime());

    }
    throw new IllegalStateException();
  }

  /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
  public boolean isSet(_Fields field) {
    if (field == null) {
      throw new IllegalArgumentException();
    }

    switch (field) {
    case TASK_ID:
      return isSetTaskID();
    case PROGRESS:
      return isSetProgress();
    case STATE:
      return isSetState();
    case DIAGNOSTIC_INFO:
      return isSetDiagnosticInfo();
    case STATE_STRING:
      return isSetStateString();
    case TASK_TRACKER:
      return isSetTaskTracker();
    case START_TIME:
      return isSetStartTime();
    case FINISH_TIME:
      return isSetFinishTime();
    case OUTPUT_SIZE:
      return isSetOutputSize();
    case PHASE:
      return isSetPhase();
    case COUNTERS:
      return isSetCounters();
    case SHUFFLE_FINISH_TIME:
      return isSetShuffleFinishTime();
    case SORT_FINISH_TIME:
      return isSetSortFinishTime();
    case MAP_FINISH_TIME:
      return isSetMapFinishTime();
    }
    throw new IllegalStateException();
  }

  @Override
  public boolean equals(Object that) {
    if (that == null)
      return false;
    if (that instanceof ThriftTaskStatus)
      return this.equals((ThriftTaskStatus)that);
    return false;
  }

  public boolean equals(ThriftTaskStatus that) {
    if (that == null)
      return false;

    boolean this_present_taskID = true && this.isSetTaskID();
    boolean that_present_taskID = true && that.isSetTaskID();
    if (this_present_taskID || that_present_taskID) {
      if (!(this_present_taskID && that_present_taskID))
        return false;
      if (!this.taskID.equals(that.taskID))
        return false;
    }

    boolean this_present_progress = true;
    boolean that_present_progress = true;
    if (this_present_progress || that_present_progress) {
      if (!(this_present_progress && that_present_progress))
        return false;
      if (this.progress != that.progress)
        return false;
    }

    boolean this_present_state = true && this.isSetState();
    boolean that_present_state = true && that.isSetState();
    if (this_present_state || that_present_state) {
      if (!(this_present_state && that_present_state))
        return false;
      if (!this.state.equals(that.state))
        return false;
    }

    boolean this_present_diagnosticInfo = true && this.isSetDiagnosticInfo();
    boolean that_present_diagnosticInfo = true && that.isSetDiagnosticInfo();
    if (this_present_diagnosticInfo || that_present_diagnosticInfo) {
      if (!(this_present_diagnosticInfo && that_present_diagnosticInfo))
        return false;
      if (!this.diagnosticInfo.equals(that.diagnosticInfo))
        return false;
    }

    boolean this_present_stateString = true && this.isSetStateString();
    boolean that_present_stateString = true && that.isSetStateString();
    if (this_present_stateString || that_present_stateString) {
      if (!(this_present_stateString && that_present_stateString))
        return false;
      if (!this.stateString.equals(that.stateString))
        return false;
    }

    boolean this_present_taskTracker = true && this.isSetTaskTracker();
    boolean that_present_taskTracker = true && that.isSetTaskTracker();
    if (this_present_taskTracker || that_present_taskTracker) {
      if (!(this_present_taskTracker && that_present_taskTracker))
        return false;
      if (!this.taskTracker.equals(that.taskTracker))
        return false;
    }

    boolean this_present_startTime = true;
    boolean that_present_startTime = true;
    if (this_present_startTime || that_present_startTime) {
      if (!(this_present_startTime && that_present_startTime))
        return false;
      if (this.startTime != that.startTime)
        return false;
    }

    boolean this_present_finishTime = true;
    boolean that_present_finishTime = true;
    if (this_present_finishTime || that_present_finishTime) {
      if (!(this_present_finishTime && that_present_finishTime))
        return false;
      if (this.finishTime != that.finishTime)
        return false;
    }

    boolean this_present_outputSize = true;
    boolean that_present_outputSize = true;
    if (this_present_outputSize || that_present_outputSize) {
      if (!(this_present_outputSize && that_present_outputSize))
        return false;
      if (this.outputSize != that.outputSize)
        return false;
    }

    boolean this_present_phase = true && this.isSetPhase();
    boolean that_present_phase = true && that.isSetPhase();
    if (this_present_phase || that_present_phase) {
      if (!(this_present_phase && that_present_phase))
        return false;
      if (!this.phase.equals(that.phase))
        return false;
    }

    boolean this_present_counters = true && this.isSetCounters();
    boolean that_present_counters = true && that.isSetCounters();
    if (this_present_counters || that_present_counters) {
      if (!(this_present_counters && that_present_counters))
        return false;
      if (!this.counters.equals(that.counters))
        return false;
    }

    boolean this_present_shuffleFinishTime = true;
    boolean that_present_shuffleFinishTime = true;
    if (this_present_shuffleFinishTime || that_present_shuffleFinishTime) {
      if (!(this_present_shuffleFinishTime && that_present_shuffleFinishTime))
        return false;
      if (this.shuffleFinishTime != that.shuffleFinishTime)
        return false;
    }

    boolean this_present_sortFinishTime = true;
    boolean that_present_sortFinishTime = true;
    if (this_present_sortFinishTime || that_present_sortFinishTime) {
      if (!(this_present_sortFinishTime && that_present_sortFinishTime))
        return false;
      if (this.sortFinishTime != that.sortFinishTime)
        return false;
    }

    boolean this_present_mapFinishTime = true;
    boolean that_present_mapFinishTime = true;
    if (this_present_mapFinishTime || that_present_mapFinishTime) {
      if (!(this_present_mapFinishTime && that_present_mapFinishTime))
        return false;
      if (this.mapFinishTime != that.mapFinishTime)
        return false;
    }

    return true;
  }

  @Override
  public int hashCode() {
    return 0;
  }

  public int compareTo(ThriftTaskStatus other) {
    if (!getClass().equals(other.getClass())) {
      return getClass().getName().compareTo(other.getClass().getName());
    }

    int lastComparison = 0;
    ThriftTaskStatus typedOther = (ThriftTaskStatus)other;

    lastComparison = Boolean.valueOf(isSetTaskID()).compareTo(typedOther.isSetTaskID());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetTaskID()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.taskID, typedOther.taskID);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetProgress()).compareTo(typedOther.isSetProgress());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetProgress()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.progress, typedOther.progress);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetState()).compareTo(typedOther.isSetState());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetState()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.state, typedOther.state);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetDiagnosticInfo()).compareTo(typedOther.isSetDiagnosticInfo());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetDiagnosticInfo()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.diagnosticInfo, typedOther.diagnosticInfo);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetStateString()).compareTo(typedOther.isSetStateString());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetStateString()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.stateString, typedOther.stateString);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetTaskTracker()).compareTo(typedOther.isSetTaskTracker());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetTaskTracker()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.taskTracker, typedOther.taskTracker);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetStartTime()).compareTo(typedOther.isSetStartTime());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetStartTime()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.startTime, typedOther.startTime);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetFinishTime()).compareTo(typedOther.isSetFinishTime());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetFinishTime()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.finishTime, typedOther.finishTime);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetOutputSize()).compareTo(typedOther.isSetOutputSize());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetOutputSize()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.outputSize, typedOther.outputSize);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetPhase()).compareTo(typedOther.isSetPhase());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetPhase()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.phase, typedOther.phase);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetCounters()).compareTo(typedOther.isSetCounters());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetCounters()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.counters, typedOther.counters);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetShuffleFinishTime()).compareTo(typedOther.isSetShuffleFinishTime());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetShuffleFinishTime()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.shuffleFinishTime, typedOther.shuffleFinishTime);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetSortFinishTime()).compareTo(typedOther.isSetSortFinishTime());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetSortFinishTime()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sortFinishTime, typedOther.sortFinishTime);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetMapFinishTime()).compareTo(typedOther.isSetMapFinishTime());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetMapFinishTime()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.mapFinishTime, typedOther.mapFinishTime);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    return 0;
  }

  public _Fields fieldForId(int fieldId) {
    return _Fields.findByThriftId(fieldId);
  }

  public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
    org.apache.thrift.protocol.TField field;
    iprot.readStructBegin();
    while (true)
    {
      field = iprot.readFieldBegin();
      if (field.type == org.apache.thrift.protocol.TType.STOP) { 
        break;
      }
      switch (field.id) {
        case 1: // TASK_ID
          if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
            this.taskID = new ThriftTaskAttemptID();
            this.taskID.read(iprot);
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 2: // PROGRESS
          if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
            this.progress = iprot.readDouble();
            setProgressIsSet(true);
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 3: // STATE
          if (field.type == org.apache.thrift.protocol.TType.I32) {
            this.state = ThriftTaskState.findByValue(iprot.readI32());
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 4: // DIAGNOSTIC_INFO
          if (field.type == org.apache.thrift.protocol.TType.STRING) {
            this.diagnosticInfo = iprot.readString();
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 5: // STATE_STRING
          if (field.type == org.apache.thrift.protocol.TType.STRING) {
            this.stateString = iprot.readString();
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 6: // TASK_TRACKER
          if (field.type == org.apache.thrift.protocol.TType.STRING) {
            this.taskTracker = iprot.readString();
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 7: // START_TIME
          if (field.type == org.apache.thrift.protocol.TType.I64) {
            this.startTime = iprot.readI64();
            setStartTimeIsSet(true);
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 8: // FINISH_TIME
          if (field.type == org.apache.thrift.protocol.TType.I64) {
            this.finishTime = iprot.readI64();
            setFinishTimeIsSet(true);
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 9: // OUTPUT_SIZE
          if (field.type == org.apache.thrift.protocol.TType.I64) {
            this.outputSize = iprot.readI64();
            setOutputSizeIsSet(true);
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 10: // PHASE
          if (field.type == org.apache.thrift.protocol.TType.I32) {
            this.phase = ThriftTaskPhase.findByValue(iprot.readI32());
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 11: // COUNTERS
          if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
            this.counters = new ThriftGroupList();
            this.counters.read(iprot);
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 12: // SHUFFLE_FINISH_TIME
          if (field.type == org.apache.thrift.protocol.TType.I64) {
            this.shuffleFinishTime = iprot.readI64();
            setShuffleFinishTimeIsSet(true);
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 13: // SORT_FINISH_TIME
          if (field.type == org.apache.thrift.protocol.TType.I64) {
            this.sortFinishTime = iprot.readI64();
            setSortFinishTimeIsSet(true);
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 14: // MAP_FINISH_TIME
          if (field.type == org.apache.thrift.protocol.TType.I64) {
            this.mapFinishTime = iprot.readI64();
            setMapFinishTimeIsSet(true);
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        default:
          org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
      }
      iprot.readFieldEnd();
    }
    iprot.readStructEnd();

    // check for required fields of primitive type, which can't be checked in the validate method
    validate();
  }

  public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
    validate();

    oprot.writeStructBegin(STRUCT_DESC);
    if (this.taskID != null) {
      oprot.writeFieldBegin(TASK_ID_FIELD_DESC);
      this.taskID.write(oprot);
      oprot.writeFieldEnd();
    }
    oprot.writeFieldBegin(PROGRESS_FIELD_DESC);
    oprot.writeDouble(this.progress);
    oprot.writeFieldEnd();
    if (this.state != null) {
      oprot.writeFieldBegin(STATE_FIELD_DESC);
      oprot.writeI32(this.state.getValue());
      oprot.writeFieldEnd();
    }
    if (this.diagnosticInfo != null) {
      oprot.writeFieldBegin(DIAGNOSTIC_INFO_FIELD_DESC);
      oprot.writeString(this.diagnosticInfo);
      oprot.writeFieldEnd();
    }
    if (this.stateString != null) {
      oprot.writeFieldBegin(STATE_STRING_FIELD_DESC);
      oprot.writeString(this.stateString);
      oprot.writeFieldEnd();
    }
    if (this.taskTracker != null) {
      oprot.writeFieldBegin(TASK_TRACKER_FIELD_DESC);
      oprot.writeString(this.taskTracker);
      oprot.writeFieldEnd();
    }
    oprot.writeFieldBegin(START_TIME_FIELD_DESC);
    oprot.writeI64(this.startTime);
    oprot.writeFieldEnd();
    oprot.writeFieldBegin(FINISH_TIME_FIELD_DESC);
    oprot.writeI64(this.finishTime);
    oprot.writeFieldEnd();
    oprot.writeFieldBegin(OUTPUT_SIZE_FIELD_DESC);
    oprot.writeI64(this.outputSize);
    oprot.writeFieldEnd();
    if (this.phase != null) {
      oprot.writeFieldBegin(PHASE_FIELD_DESC);
      oprot.writeI32(this.phase.getValue());
      oprot.writeFieldEnd();
    }
    if (this.counters != null) {
      oprot.writeFieldBegin(COUNTERS_FIELD_DESC);
      this.counters.write(oprot);
      oprot.writeFieldEnd();
    }
    oprot.writeFieldBegin(SHUFFLE_FINISH_TIME_FIELD_DESC);
    oprot.writeI64(this.shuffleFinishTime);
    oprot.writeFieldEnd();
    oprot.writeFieldBegin(SORT_FINISH_TIME_FIELD_DESC);
    oprot.writeI64(this.sortFinishTime);
    oprot.writeFieldEnd();
    oprot.writeFieldBegin(MAP_FINISH_TIME_FIELD_DESC);
    oprot.writeI64(this.mapFinishTime);
    oprot.writeFieldEnd();
    oprot.writeFieldStop();
    oprot.writeStructEnd();
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder("ThriftTaskStatus(");
    boolean first = true;

    sb.append("taskID:");
    if (this.taskID == null) {
      sb.append("null");
    } else {
      sb.append(this.taskID);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("progress:");
    sb.append(this.progress);
    first = false;
    if (!first) sb.append(", ");
    sb.append("state:");
    if (this.state == null) {
      sb.append("null");
    } else {
      sb.append(this.state);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("diagnosticInfo:");
    if (this.diagnosticInfo == null) {
      sb.append("null");
    } else {
      sb.append(this.diagnosticInfo);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("stateString:");
    if (this.stateString == null) {
      sb.append("null");
    } else {
      sb.append(this.stateString);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("taskTracker:");
    if (this.taskTracker == null) {
      sb.append("null");
    } else {
      sb.append(this.taskTracker);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("startTime:");
    sb.append(this.startTime);
    first = false;
    if (!first) sb.append(", ");
    sb.append("finishTime:");
    sb.append(this.finishTime);
    first = false;
    if (!first) sb.append(", ");
    sb.append("outputSize:");
    sb.append(this.outputSize);
    first = false;
    if (!first) sb.append(", ");
    sb.append("phase:");
    if (this.phase == null) {
      sb.append("null");
    } else {
      sb.append(this.phase);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("counters:");
    if (this.counters == null) {
      sb.append("null");
    } else {
      sb.append(this.counters);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("shuffleFinishTime:");
    sb.append(this.shuffleFinishTime);
    first = false;
    if (!first) sb.append(", ");
    sb.append("sortFinishTime:");
    sb.append(this.sortFinishTime);
    first = false;
    if (!first) sb.append(", ");
    sb.append("mapFinishTime:");
    sb.append(this.mapFinishTime);
    first = false;
    sb.append(")");
    return sb.toString();
  }

  public void validate() throws org.apache.thrift.TException {
    // check for required fields
  }

  private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
    try {
      write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
    } catch (org.apache.thrift.TException te) {
      throw new java.io.IOException(te);
    }
  }

  private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
    try {
      // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
      __isset_bit_vector = new BitSet(1);
      read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
    } catch (org.apache.thrift.TException te) {
      throw new java.io.IOException(te);
    }
  }

}

