code: public void setWithTotal() throws IOException {
      if (collectorType.equals(DataCollector.COLLECTOR_TYPE_LIST)) {
        if (segmentName != null) {
          throw new IOException("can't get total with segmentRegistration");
        } else {
          withTotal = true;
        }
      } else {
        throw new IOException(
            "can't get total for dataCollector of type " + collectorType);
      }
    }
docs: Sets the with total.
  
  @throws IOException Signals that an I/O exception has occurred.