public int getSerializedSize() {
    int size = memoizedSerializedSize;
    if (size != -1) return size;

    size = 0;
    if (!getDatasetIdBytes().isEmpty()) {
      size += com.google.protobuf.CodedOutputStream.computeBytesSize(1, getDatasetIdBytes());
    }
    {
      int dataSize = 0;
      for (int i = 0; i < sourceUris_.size(); i++) {
        dataSize +=
            com.google.protobuf.CodedOutputStream.computeBytesSizeNoTag(
                sourceUris_.getByteString(i));
      }
      size += dataSize;
      size += 1 * getSourceUrisList().size();
    }
    if (!getReferenceSetIdBytes().isEmpty()) {
      size += com.google.protobuf.CodedOutputStream.computeBytesSize(4, getReferenceSetIdBytes());
    }
    if (partitionStrategy_
        != com.google.genomics.v1.ImportReadGroupSetsRequest.PartitionStrategy
            .PARTITION_STRATEGY_UNSPECIFIED.getNumber()) {
      size += com.google.protobuf.CodedOutputStream.computeEnumSize(5, partitionStrategy_);
    }
    memoizedSerializedSize = size;
    return size;
  }
 public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
   getSerializedSize();
   if (!getDatasetIdBytes().isEmpty()) {
     output.writeBytes(1, getDatasetIdBytes());
   }
   for (int i = 0; i < sourceUris_.size(); i++) {
     output.writeBytes(2, sourceUris_.getByteString(i));
   }
   if (!getReferenceSetIdBytes().isEmpty()) {
     output.writeBytes(4, getReferenceSetIdBytes());
   }
   if (partitionStrategy_
       != com.google.genomics.v1.ImportReadGroupSetsRequest.PartitionStrategy
           .PARTITION_STRATEGY_UNSPECIFIED.getNumber()) {
     output.writeEnum(5, partitionStrategy_);
   }
 }