code: protected void closeMailConnection(Connection<MailResourcesHolder> mailConnection) throws IOException
      {
          if(mailConnection!=null)
          {
              //get logger
              Logger logger=this.getLogger();
              
              //release connection
              logger.logInfo(new Object[]{"Closing mail connection."},null);
              mailConnection.close();
          }
      }
docs: This function closes the provided mail connection.
  
  @param   mailConnection
  The mail connection to close
  @throws  IOException
  Never thrown