/**
   * Method to send an ACK containing the filename (could actually be a directory) just taken back
   * to the client, and to ensure the client connection is kept open.
   *
   * @param multRunCommand The MULTRUN command we are implementing.
   * @param multRunDone The MULTRUN_DONE command object that will be returned to the client. We set
   *     a sensible error message in this object if this method fails.
   * @return We return true if the method succeeds, and false if an error occurs.
   * @see #lotus
   * @see #serverConnectionThread
   * @see ngat.lotus.LOTUS#log
   * @see ngat.lotus.LOTUS#error
   * @see ngat.message.ISS_INST.MULTRUN_ACK
   */
  protected boolean sendMultrunACK(
      MULTRUN multRunCommand, MULTRUN_DONE multRunDone, String filename) {
    MULTRUN_ACK multRunAck = null;

    // send acknowledge to say frames are completed.
    // diddly 4000
    lotus.log(
        Logging.VERBOSITY_INTERMEDIATE,
        this.getClass().getName()
            + ":sendMultrunACK:Sending ACK with exposure time "
            + multRunCommand.getExposureTime()
            + " plus ramp overhead "
            + 4000
            + " plus default ACK time "
            + serverConnectionThread.getDefaultAcknowledgeTime()
            + ".");
    multRunAck = new MULTRUN_ACK(multRunCommand.getId());
    multRunAck.setTimeToComplete(
        multRunCommand.getExposureTime()
            + 4000
            + serverConnectionThread.getDefaultAcknowledgeTime());
    multRunAck.setFilename(filename);
    try {
      serverConnectionThread.sendAcknowledge(multRunAck);
    } catch (IOException e) {
      lotus.error(this.getClass().getName() + ":sendMultrunACK:sendAcknowledge:", e);
      multRunDone.setErrorNum(LOTUSConstants.LOTUS_ERROR_CODE_BASE + 1202);
      multRunDone.setErrorString("sendMultrunACK:sendAcknowledge:" + e.toString());
      multRunDone.setSuccessful(false);
      return false;
    }
    return true;
  }