code: public void write(DataOutput out) throws IOException {
      taskid.write(out);
      out.writeFloat(progress);
      out.writeInt(numSlots);
      WritableUtils.writeEnum(out, runState);
      Text.writeString(out, diagnosticInfo);
      Text.writeString(out, stateString);
      WritableUtils.writeEnum(out, phase);
      out.writeLong(startTime);
      out.writeLong(finishTime);
      out.writeBoolean(includeCounters);
      out.writeLong(outputSize);
      if (includeCounters) {
        counters.write(out);
      }
      nextRecordRange.write(out);
    }
docs: ////////////////////////////////////////////